83% toolbar-links

Code Review | Toolbar Links

WordPress plugin Toolbar Links scored83%from 54 tests.

About plugin

  • Plugin page: toolbar-links
  • Plugin version: 1.4
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.0-6.2
  • WordPress version: 6.3.1
  • First release: Feb 14, 2023
  • Latest release: May 9, 2023
  • Number of updates: 22
  • Update frequency: every 3.9 days
  • Top authors: pluginsclub (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /312 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
The plugin installed gracefully, with no errors

Server metrics [RAM: ▲0.15MB] [CPU: ▲0.19ms] 75% from 4 tests

Analyzing server-side resources used by Toolbar Links
The following require your attention
  • CPU: The total CPU usage must kept under 500.00ms (currently 1,632.87ms on /wp-admin/options-general.php?page=tl-settings)
PageMemory (MB)CPU Time (ms)
Home /3.52 ▲0.0634.16 ▼5.90
Dashboard /wp-admin3.48 ▲0.1852.45 ▲1.40
Posts /wp-admin/edit.php3.59 ▲0.2456.42 ▲2.36
Add New Post /wp-admin/post-new.php6.08 ▲0.19100.84 ▲2.90
Media Library /wp-admin/upload.php3.40 ▲0.1742.85 ▲5.37
Toolbar Links /wp-admin/options-general.php?page=tl-settings3.371,632.87

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

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

Browser metrics Passed 4 tests

An overview of browser requirements for Toolbar Links
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,071 ▲30013.57 ▼0.942.43 ▲0.3545.40 ▼1.54
Dashboard /wp-admin2,344 ▲1625.89 ▼0.13109.64 ▲6.2338.91 ▼4.86
Posts /wp-admin/edit.php2,233 ▲1472.08 ▲0.0843.49 ▲7.1435.88 ▼0.62
Add New Post /wp-admin/post-new.php1,638 ▲11923.16 ▼0.18659.05 ▲28.3057.62 ▲4.80
Media Library /wp-admin/upload.php1,529 ▲1444.16 ▼0.04116.66 ▲13.4447.93 ▲3.15
Toolbar Links /wp-admin/options-general.php?page=tl-settings1,1361.7728.9331.74

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
  • Zombie WordPress options were found after uninstall: 6 options
    • can_compress_scripts
    • widget_recent-comments
    • widget_recent-posts
    • theysaidso_admin_options
    • db_upgraded
    • widget_theysaidso_widget

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
Everything seems fine, however this is by no means an exhaustive test

SRP 50% from 2 tests

🔹 Tests weight: 20 | A shallow check of the single-responsibility principle; PHP files should perform no action - including output of placeholder text - and trigger no errors when accessed directly
Please fix the following items
  • 7× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/toolbar-links/includes/publish-post.php:7
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/toolbar-links/includes/wp-admin-menu.php:282
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/toolbar-links/includes/toolbar-off.php:9
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/toolbar-links/includes/delete-post.php:7
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/toolbar-links/includes/disable-wp-logo.php:7
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/toolbar-links/includes/disable-wp-logo.php:7
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/toolbar-links/includes/admin-menu.php:392

User-side errors Passed 1 test

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

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 94% from 16 tests

You should put a lot of thought into formatting readme.txt as it is used by WordPress.org to prepare the public listing of your plugin
Please fix the following attributes:
  • Screenshots: These screenshots do not have images: #1 (Toolbar links), #2 (Plugin settings page)
Please take inspiration from this readme.txt

toolbar-links/toolbar-links.php 92% from 13 tests

Analyzing the main PHP file in "Toolbar Links" version 1.4
Please make the necessary changes and fix the following:
  • Requires at least: Required version does not match the one declared in readme.txt ("5.8" instead of "5.0")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are considered dangerous and should not be included with any WordPress plugin
Good job! No executable or dangerous file extensions detected1,522 lines of code in 14 files:
LanguageFilesBlank linesComment linesLines of code
PHP817945946
CSS4205540
JavaScript20736

PHP code Passed 2 tests

This plugin's cyclomatic complexity and code structure detailed below
This plugin has no cyclomatic complexity issues
Cyclomatic complexity
Average complexity per logical line of code0.24
Average class complexity4.00
▷ Minimum class complexity3.00
▷ Maximum class complexity5.00
Average method complexity2.50
▷ Minimum method complexity1.00
▷ Maximum method complexity5.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes2
▷ Abstract classes00.00%
▷ Concrete classes2100.00%
▷ Final classes00.00%
Methods4
▷ Static methods00.00%
▷ Public methods4100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions15
▷ Named functions15100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
7 PNG files occupy 0.22MB with 0.14MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
includes/images/2.png28.96KB10.56KB▼ 63.54%
includes/images/pluginsclub_logo_black.png22.36KB10.65KB▼ 52.36%
includes/images/6.png28.11KB9.96KB▼ 64.57%
includes/images/1.png28.88KB10.17KB▼ 64.80%
includes/images/5.png29.19KB10.35KB▼ 64.54%