83% stronger-admin-bar

Code Review | Stronger Admin Bar

WordPress plugin Stronger Admin Bar scored83%from 54 tests.

About plugin

  • Plugin page: stronger-admin-bar
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0-3.9
  • WordPress version: 6.3.1
  • First release: May 19, 2014
  • Latest release: May 26, 2014
  • Number of updates: 6
  • Update frequency: every 1.2 days
  • Top authors: silver530 (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /703 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
This plugin's installer ran successfully

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

Server-side resources used by Stronger Admin Bar
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.46 ▲0.0036.12 ▼5.98
Dashboard /wp-admin3.31 ▲0.0048.14 ▼2.84
Posts /wp-admin/edit.php3.36 ▲0.0044.27 ▼2.44
Add New Post /wp-admin/post-new.php5.89 ▲0.0082.10 ▼7.86
Media Library /wp-admin/upload.php3.23 ▲0.0033.87 ▼0.25

Server storage [IO: ▲0.06MB] [DB: ▲0.00MB] Passed 3 tests

A short overview of filesystem and database impact
This plugin installed successfully
Filesystem: 10 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-posts
can_compress_scripts
db_upgraded
widget_recent-comments
theysaidso_admin_options
widget_theysaidso_widget

Browser metrics Passed 4 tests

This is an overview of browser requirements for Stronger Admin Bar
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,802 ▲6713.20 ▼1.101.58 ▼0.2842.56 ▼6.46
Dashboard /wp-admin2,169 ▼226.08 ▲0.20100.38 ▼5.6536.88 ▼4.62
Posts /wp-admin/edit.php2,067 ▼251.96 ▼0.0735.76 ▼4.7431.73 ▼5.75
Add New Post /wp-admin/post-new.php1,521 ▼1223.17 ▼0.25687.80 ▲37.0854.91 ▲0.01
Media Library /wp-admin/upload.php1,354 ▼314.19 ▲0.0296.03 ▼6.6441.31 ▼1.65

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
You still need to fix the following
  • The uninstall procedure has failed, leaving 6 options in the database
    • can_compress_scripts
    • widget_theysaidso_widget
    • widget_recent-posts
    • theysaidso_admin_options
    • db_upgraded
    • widget_recent-comments

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Even though everything seems fine, this is not an exhaustive test

SRP 50% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle: PHP files have to remain inert when accessed directly, throwing no errors and performing no actions
Almost there! Just fix the following items
  • 1× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/stronger-admin-bar/stronger-admin-bar.php:41

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 88% from 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
Attributes that require attention:
  • Screenshots: Please add an image for screenshot #1 (screenshot-1.png)
  • Tags: There are too many tags (12 tag instead of maximum 10)
The official readme.txt might help

stronger-admin-bar/stronger-admin-bar.php 92% from 13 tests

Analyzing the main PHP file in "Stronger Admin Bar" version 1.0
Please take the time to fix the following:
  • Text Domain: Please use dashes and lowercase characters for text domains

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short review of files and their extensions; it is not recommended to include executable files
Everything looks great! No dangerous files found in this plugin155 lines of code in 6 files:
LanguageFilesBlank linesComment linesLines of code
PO File42872132
PHP2173023

PHP code Passed 2 tests

This is a short overview of cyclomatic complexity and code structure for this plugin
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity
Average complexity per logical line of code0.00
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%
Functions2
▷ Named functions2100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Often times overlooked, PNG files can occupy unnecessary space in your plugin
1 PNG file occupies 0.03MB with 0.02MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
screenshot-1.png34.48KB11.21KB▼ 67.49%