89% better-wp-admin-bar

Code Review | Better WP Admin Bar

WordPress plugin Better WP Admin Bar scored89%from 54 tests.

About plugin

  • Plugin page: better-wp-admin-bar
  • Plugin version: 1.2
  • PHP compatiblity: 5.2.4+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.9-6.2
  • WordPress version: 6.3.1
  • First release: May 21, 2022
  • Latest release: May 11, 2023
  • Number of updates: 20
  • Update frequency: every 17.8 days
  • Top authors: daltonwalsh (100%)

Code review

54 tests

User reviews

2 reviews

Install metrics

10+ active /1,370 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
This plugin's installer ran successfully

Server metrics [RAM: ▲0.00MB] [CPU: ▼1.79ms] Passed 4 tests

Server-side resources used by Better WP Admin Bar
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.46 ▲0.0138.54 ▼4.10
Dashboard /wp-admin3.31 ▲0.0043.92 ▲0.44
Posts /wp-admin/edit.php3.36 ▲0.0043.83 ▼2.90
Add New Post /wp-admin/post-new.php5.89 ▲0.0091.46 ▼0.60
Media Library /wp-admin/upload.php3.23 ▲0.0037.04 ▲3.67

Server storage [IO: ▲0.32MB] [DB: ▲0.07MB] Passed 3 tests

Input-output and database impact of this plugin
The plugin installed successfully
Filesystem: 10 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-posts
theysaidso_admin_options
can_compress_scripts
widget_recent-comments
db_upgraded
widget_theysaidso_widget

Browser metrics Passed 4 tests

An overview of browser requirements for Better WP Admin Bar
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,832 ▲7514.47 ▲0.362.97 ▲0.8345.71 ▼2.37
Dashboard /wp-admin2,209 ▲184.84 ▼0.0996.63 ▼8.1339.85 ▲0.93
Posts /wp-admin/edit.php2,086 ▼32.05 ▲0.0336.59 ▲1.9231.33 ▼2.52
Add New Post /wp-admin/post-new.php1,540 ▲723.46 ▲0.40684.08 ▲25.8251.27 ▼7.37
Media Library /wp-admin/upload.php1,388 ▼04.29 ▲0.0993.01 ▼2.3243.99 ▲1.03

Uninstaller [IO: ▲0.00MB] [DB: ▲0.07MB] 75% from 4 tests

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
Please fix the following items
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • widget_recent-comments
    • can_compress_scripts
    • db_upgraded
    • widget_theysaidso_widget
    • widget_recent-posts
    • theysaidso_admin_options

Smoke tests Passed 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Good news, no errors were detected

SRP Passed 2 tests

🔹 Tests weight: 20 | The single-responsibility principle applies for WordPress plugins as well - please make sure your PHP files perform no actions when accessed directly
No output text or server-side errors detected on direct access of PHP files

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
No browser issues were found

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 94% from 16 tests

Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
Attributes that require attention:
  • Screenshots: Screenshot #1 (Screenshot of what the tab on the updated admin looks like. (images/screenshot.png)) image required
You can look at the official readme.txt

better-wp-admin-bar/better-wp-admin-bar.php 92% from 13 tests

The entry point to "Better WP Admin Bar" version 1.2 is a PHP file that has certain tags in its header comment area
Please take the time to fix the following:
  • Domain Path: The domain path points to a folder that does not exist ("/languages")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is a short overview of programming languages used in this plugin, detecting executable files
Success! There were no dangerous files found in this plugin36 lines of code in 4 files:
LanguageFilesBlank linesComment linesLines of code
SVG10022
PHP131112
CSS1001
JavaScript1001

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.40
Average class complexity0.00
▷ Minimum class complexity0.00
▷ Maximum class complexity0.00
Average method complexity0.00
▷ Minimum method complexity0.00
▷ Maximum method complexity0.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes0
▷ Abstract classes00.00%
▷ Concrete classes00.00%
▷ Final classes00.00%
Methods0
▷ Static methods00.00%
▷ Public methods00.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions1
▷ Named functions1100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Using a strong compression for your PNG files is a great way to speed-up your plugin
3 compressed PNG files occupy 0.25MB
Potential savings
Compression of 3 random PNG files using pngquant
FileSize - originalSize - compressedSavings
assets/banner-772x250.png127.50KB140.68KB0.00%
assets/images/banner-772x250.png127.50KB140.68KB0.00%
assets/images/screenshot.png0.90KB0.92KB0.00%