84% admin-bar-tools

Code Review | Admin Bar Tools

WordPress plugin Admin Bar Tools scored 84% from 54 tests.

About plugin

  • Plugin page: admin-bar-tools
  • Plugin version: 1.4.3
  • PHP compatiblity: 7.3.0+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.5.1-5.8.1
  • WordPress version: 5.8.1
  • First release: Nov 5, 2020
  • Latest release: Nov 6, 2021
  • Number of updates: 22
  • Update frequency: every 17.3 days
  • Top authors: braveryk7 (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 638 total downloads

Benchmarks

Plugin footprint 82% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
This plugin's installer ran successfully

Server metrics [RAM: ▲0.16MB] [CPU: ▼138.57ms] Passed 4 tests

Server-side resources used by Admin Bar Tools
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /2.98 ▲0.2637.91 ▲17.75
Dashboard /wp-admin3.21 ▲0.1549.14 ▲4.27
Posts /wp-admin/edit.php3.32 ▲0.2150.33 ▲6.13
Add New Post /wp-admin/post-new.php5.60 ▲0.1693.61 ▼565.47
Media Library /wp-admin/upload.php3.15 ▲0.1439.92 ▲0.81
Admin Bar Tools /wp-admin/options-general.php?page=admin-bar-tools3.1438.25

Server storage [IO: ▲0.40MB] [DB: ▲0.00MB] 67% from 3 tests

How much does this plugin use your filesystem and database?
It is recommended to fix the following issues
  • Illegal file modification detected: 2 files (0.00KB) outside of "wp-content/plugins/admin-bar-tools/" and "wp-content/uploads/"
    • (new file) "wp-content/plugins/admin-bar-tools/img/icon-128\303\227128.jpg"
    • (new file) "wp-content/plugins/admin-bar-tools/img/icon-256\303\227256.jpg"
Filesystem: 37 new files
Database: no new tables, 4 new options
New WordPress options
abt_db_version
abt_sc
abt_status
abt_locale

Browser metrics Passed 4 tests

Admin Bar Tools: an overview of browser usage
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,804 ▲20816.04 ▲0.3612.60 ▲1.5851.04 ▲3.50
Dashboard /wp-admin3,026 ▲955.90 ▼0.03134.58 ▼3.56109.63 ▲7.52
Posts /wp-admin/edit.php2,789 ▲502.85 ▲0.0063.63 ▼2.6388.44 ▼7.86
Add New Post /wp-admin/post-new.php1,707 ▼16518.91 ▼0.33380.65 ▲0.04105.83 ▼12.13
Media Library /wp-admin/upload.php1,860 ▲505.02 ▼0.01151.92 ▼8.68121.54 ▲0.69
Admin Bar Tools /wp-admin/options-general.php?page=admin-bar-tools1,5048.39173.80119.61

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
You still need to fix the following
  • This plugin cannot be uninstalled
    • > Deprecated in wp-includes/class-wp-hook.php+303
    Non-static method Abt_Connect_Database::delete_wp_options() should not be called statically

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Everything seems fine, however this is by no means 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
Please fix the following
  • 8× GET requests to PHP files return non-empty strings:
    • > /wp-content/plugins/admin-bar-tools/class/class-abt-admin-page.php
    • > /wp-content/plugins/admin-bar-tools/class/class-abt-add-admin-bar.php
    • > /wp-content/plugins/admin-bar-tools/class/class-abt-connect-database.php
    • > /wp-content/plugins/admin-bar-tools/admin-bar-tools.php
    • > /wp-content/plugins/admin-bar-tools/class/class-abt-admin-settings-page.php
    • > /wp-content/plugins/admin-bar-tools/class/class-abt-return-data.php
    • > /wp-content/plugins/admin-bar-tools/modules/cancel-activate.php
    • > /wp-content/plugins/admin-bar-tools/lib/abt-strings.php

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
No browser issues were found

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

It's important to format your readme.txt file correctly as it is parsed for the public listing of your plugin
4 plugin tags: admin bar, admin menu, development, toolbar

admin-bar-tools/admin-bar-tools.php Passed 13 tests

"Admin Bar Tools" version 1.4.3's main PHP file describes plugin functionality and also serves as the entry point to any WordPress functionality
62 characters long description:
A plugin that allows you to add useful links to the admin bar.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | An overview of files in this plugin; executable files are not allowed
Success! There were no dangerous files found in this plugin999 lines of code in 15 files:
LanguageFilesBlank linesComment linesLines of code
PHP1095261810
PO File27586186
CSS1001
JSON1001
JavaScript1001

PHP code Passed 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.37
Average class complexity11.00
▷ Minimum class complexity2.00
▷ Maximum class complexity23.00
Average method complexity3.31
▷ Minimum method complexity1.00
▷ Maximum method complexity23.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes6
▷ Abstract classes00.00%
▷ Concrete classes6100.00%
▷ Final classes00.00%
Methods26
▷ Static methods415.38%
▷ Public methods2388.46%
▷ Protected methods00.00%
▷ Private methods311.54%
Functions3
▷ Named functions3100.00%
▷ Anonymous functions00.00%
Constants3
▷ Global constants00.00%
▷ Class constants3100.00%
▷ Public constants3100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
18 compressed PNG files occupy 0.31MB
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
img/original/linkedin_banner_image_1.png8.84KB8.86KB0.00%
img/original/pinterest_profile_image.png2.27KB2.27KB0.00%
img/original/pinterest_board_photo.png4.98KB5.83KB0.00%
img/screenshot/screenshot-2.png81.86KB23.25KB▼ 71.60%
img/original/logo_transparent.png7.97KB7.97KB0.00%