84% better-my-sites-menu

Code Review | Better My Sites Menu

WordPress plugin Better My Sites Menu scored84%from 54 tests.

About plugin

  • Plugin page: better-my-sites-menu
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0.0-3.5.2
  • WordPress version: 6.3.1
  • First release: Aug 15, 2013
  • Latest release: Aug 15, 2013
  • Number of updates: 3
  • Update frequency: N/A
  • Top authors: BrashRebel (100%)

Code review

54 tests

User reviews

2 reviews

Install metrics

10+ active /1,522 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
Installer ran successfully

Server metrics [RAM: ▲0.01MB] [CPU: ▼6.29ms] Passed 4 tests

Server-side resources used by Better My Sites Menu
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.48 ▲0.0237.70 ▼0.78
Dashboard /wp-admin3.33 ▼0.0247.47 ▼15.29
Posts /wp-admin/edit.php3.38 ▲0.0243.88 ▼4.33
Add New Post /wp-admin/post-new.php5.91 ▲0.0290.06 ▼4.76
Media Library /wp-admin/upload.php3.25 ▲0.0236.37 ▲3.51

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

How much does this plugin use your filesystem and database?
The plugin installed successfully
Filesystem: 2 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-comments
can_compress_scripts
widget_recent-posts
widget_theysaidso_widget
theysaidso_admin_options
db_upgraded

Browser metrics Passed 4 tests

A check of browser resources used by Better My Sites Menu
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,800 ▲5413.76 ▼0.541.79 ▲0.0236.55 ▼6.87
Dashboard /wp-admin2,206 ▲215.86 ▲1.00109.82 ▼9.3543.13 ▼2.45
Posts /wp-admin/edit.php2,086 ▼31.99 ▼0.0734.25 ▼6.7136.19 ▲0.70
Add New Post /wp-admin/post-new.php1,534 ▲1223.13 ▼0.16670.25 ▼9.9563.31 ▲7.69
Media Library /wp-admin/upload.php1,391 ▲94.18 ▼0.0196.50 ▼3.6043.15 ▼0.03

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
The following items require your attention
  • The uninstall procedure has failed, leaving 6 options in the database
    • db_upgraded
    • theysaidso_admin_options
    • widget_recent-posts
    • can_compress_scripts
    • widget_recent-comments
    • widget_theysaidso_widget

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
Even though everything seems fine, this is not an exhaustive test

SRP 50% from 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
The following issues need your attention
  • 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/better-my-sites-menu/better-my-sites-menu.php:22

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 Passed 29 tests

readme.txt Passed 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
4 plugin tags: admin bar, my sites, multisite, toolbar

better-my-sites-menu/better-my-sites-menu.php Passed 13 tests

"Better My Sites Menu" version 1.0's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
72 characters long description:
Basic adjustments to improve the My Sites menu for multiple-site admins.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short glimpse at programming languages used with this plugin and a check that no dangerous files are present
Good job! No executable or dangerous file extensions detected122 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code
PHP12320122

PHP code Passed 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
This plugin has no cyclomatic complexity problems
Cyclomatic complexity
Average complexity per logical line of code0.39
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%
Functions3
▷ Named functions3100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
No PNG files were detected