84% better-plugin-compatibility-control

Code Review | Better Plugin Compatibility Control

WordPress plugin Better Plugin Compatibility Control scored84%from 54 tests.

About plugin

  • Plugin page: better-plugin-com...
  • Plugin version: 6.4.0
  • PHP version: 7.4.16
  • WordPress compatibility: 2.9-6.4.99
  • WordPress version: 6.3.1
  • First release: Dec 30, 2008
  • Latest release: Nov 6, 2023
  • Number of updates: 144
  • Update frequency: every 37.7 days
  • Top authors: Alphawolf (100%)

Code review

54 tests

User reviews

19 reviews

Install metrics

5,000+ active /117,292 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
This plugin's installer ran successfully

Server metrics [RAM: ▲0.02MB] [CPU: ▼5.87ms] Passed 4 tests

Analyzing server-side resources used by Better Plugin Compatibility Control
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.49 ▲0.0340.12 ▲1.89
Dashboard /wp-admin3.34 ▼0.0051.25 ▼9.87
Posts /wp-admin/edit.php3.39 ▲0.0450.28 ▲1.10
Add New Post /wp-admin/post-new.php5.92 ▲0.0482.35 ▼13.71
Media Library /wp-admin/upload.php3.27 ▲0.0432.97 ▼0.98

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

Filesystem and database footprint
The plugin installed successfully
Filesystem: 25 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

Better Plugin Compatibility Control: an overview of browser usage
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,790 ▲2814.22 ▲0.121.89 ▲0.3843.92 ▲1.86
Dashboard /wp-admin2,195 ▲185.51 ▼0.0487.17 ▼1.6839.16 ▲0.75
Posts /wp-admin/edit.php2,100 ▼02.02 ▲0.0535.60 ▼0.7730.04 ▼2.24
Add New Post /wp-admin/post-new.php1,526 ▼023.09 ▼0.04665.52 ▼52.1447.84 ▼8.31
Media Library /wp-admin/upload.php1,400 ▼04.18 ▼0.0194.37 ▼10.5441.32 ▼4.84

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
It is recommended to fix the following
  • The uninstall procedure has failed, leaving 6 options in the database
    • theysaidso_admin_options
    • can_compress_scripts
    • widget_theysaidso_widget
    • widget_recent-comments
    • db_upgraded
    • widget_recent-posts

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 no errors were found, 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
The following issues need your attention
  • 2× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Notice
      Undefined index: wp_version in wp-content/plugins/better-plugin-compatibility-control/better-plugin-compatibility-control.php on line 46
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_basename() in wp-content/plugins/better-plugin-compatibility-control/better-plugin-compatibility-control.php:51

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
Everything seems fine on the user side

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
8 plugin tags: compatible, plugins, plugin, compatibility, control...

better-plugin-compatibility-control/better-plugin-compatibility-control.php Passed 13 tests

Analyzing the main PHP file in "Better Plugin Compatibility Control" version 6.4.0
138 characters long description:
Adds version compatibility info to the plugins page to inform the admin at a glance if a plugin is compatible with the current WP version.

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
There were no executable files found in this plugin500 lines of code in 11 files:
LanguageFilesBlank linesComment linesLines of code
PO File1090177382
PHP144100118

PHP code Passed 2 tests

This plugin's cyclomatic complexity and code structure detailed below
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity
Average complexity per logical line of code0.62
Average class complexity26.00
▷ Minimum class complexity26.00
▷ Maximum class complexity26.00
Average method complexity4.57
▷ Minimum method complexity1.00
▷ Maximum method complexity14.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods7
▷ Static methods114.29%
▷ Public methods7100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions0
▷ Named functions00.00%
▷ Anonymous functions00.00%
Constants5
▷ Global constants5100.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
No PNG images were found in this plugin