78% surbma-wp-control

Code Review | Surbma | WP Control

WordPress plugin Surbma | WP Control scored78%from 54 tests.

About plugin

  • Plugin page: surbma-wp-control
  • Plugin version: 18.0
  • PHP compatiblity: 7.4+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.4-6.4
  • WordPress version: 6.3.1
  • First release: Jul 21, 2015
  • Latest release: Nov 16, 2023
  • Number of updates: 99
  • Update frequency: every 30.8 days
  • Top authors: Surbma (100%)

Code review

54 tests

User reviews

1 review

Install metrics

20+ active /4,903 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
Install script ran successfully

Server metrics [RAM: ▲0.08MB] [CPU: ▼6.92ms] Passed 4 tests

Analyzing server-side resources used by Surbma | WP Control
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.51 ▲0.0436.20 ▼7.02
Dashboard /wp-admin3.39 ▲0.0944.09 ▼7.92
Posts /wp-admin/edit.php3.50 ▲0.1446.05 ▲1.44
Add New Post /wp-admin/post-new.php5.99 ▲0.1092.56 ▼14.18
Media Library /wp-admin/upload.php3.33 ▲0.1035.75 ▲2.84

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

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

Browser metrics Passed 4 tests

A check of browser resources used by Surbma | WP Control
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,507 ▼25514.18 ▼0.061.44 ▼0.2235.65 ▼9.10
Dashboard /wp-admin1,901 ▼2795.44 ▼0.2187.04 ▼12.8038.24 ▼4.13
Posts /wp-admin/edit.php2,056 ▼441.97 ▲0.0238.94 ▼2.0435.26 ▲0.73
Add New Post /wp-admin/post-new.php1,515 ▼1123.07 ▼0.02675.87 ▲72.0374.61 ▲21.39
Media Library /wp-admin/upload.php1,361 ▼394.18 ▼0.0198.91 ▼3.9643.09 ▼1.54

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

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
It is recommended to fix the following
  • Zombie WordPress options were found after uninstall: 6 options
    • can_compress_scripts
    • widget_recent-posts
    • widget_recent-comments
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • db_upgraded

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Even though no errors were found, this is by no means an exhaustive test

SRP 0% from 2 tests

🔹 Tests weight: 20 | It is important to ensure that your PHP files perform no action when accessed directly, respecting the single-responsibility principle
Please take a closer look at the following
  • 1× PHP files perform the action of outputting non-empty strings when accessed directly:
    • > /wp-content/plugins/surbma-wp-control/surbma-wp-control.php
  • 13× GET requests to PHP files have triggered server-side errors or warnings (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/surbma-wp-control/lib/frontend-genesis.php:4
    • > PHP Warning
      include_once(): Failed opening 'SURBMA_WP_CONTROL_PLUGIN_DIR/pages/theme-manager.php' for inclusion (include_path='.:/usr/share/php') in wp-content/plugins/surbma-wp-control/lib/admin.php on line 6
    • > PHP Warning
      include_once(): Failed opening 'SURBMA_WP_CONTROL_PLUGIN_DIR/pages/plugin-manager.php' for inclusion (include_path='.:/usr/share/php') in wp-content/plugins/surbma-wp-control/lib/admin.php on line 5
    • > PHP Warning
      include_once(): Failed opening 'SURBMA_WP_CONTROL_PLUGIN_DIR/pages/control-page.php' for inclusion (include_path='.:/usr/share/php') in wp-content/plugins/surbma-wp-control/lib/admin.php on line 4
    • > PHP Warning
      Use of undefined constant SURBMA_WP_CONTROL_PLUGIN_DIR - assumed 'SURBMA_WP_CONTROL_PLUGIN_DIR' (this will throw an Error in a future version of PHP) in wp-content/plugins/surbma-wp-control/lib/admin.php on line 5
    • > PHP Warning
      include_once(SURBMA_WP_CONTROL_PLUGIN_DIR/pages/control-page.php): failed to open stream: No such file or directory in wp-content/plugins/surbma-wp-control/lib/admin.php on line 4
    • > PHP Warning
      include_once(SURBMA_WP_CONTROL_PLUGIN_DIR/pages/theme-manager.php): failed to open stream: No such file or directory in wp-content/plugins/surbma-wp-control/lib/admin.php on line 6
    • > PHP Warning
      include_once(SURBMA_WP_CONTROL_PLUGIN_DIR/pages/plugin-manager.php): failed to open stream: No such file or directory in wp-content/plugins/surbma-wp-control/lib/admin.php on line 5
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/surbma-wp-control/pages/control-page.php:7
    • > PHP Warning
      Use of undefined constant SURBMA_WP_CONTROL_PLUGIN_DIR - assumed 'SURBMA_WP_CONTROL_PLUGIN_DIR' (this will throw an Error in a future version of PHP) in wp-content/plugins/surbma-wp-control/lib/admin.php on line 4

User-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
Everything seems fine on the user side

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

The readme.txt file is undoubtedly the most important file in your plugin, preparing it for public listing on WordPress.org
9 plugin tags: gravityforms, soliloquy, jetpack, multisite, woothemes...

surbma-wp-control/surbma-wp-control.php 92% from 13 tests

The main PHP file in "Surbma | WP Control" ver. 18.0 adds more information about the plugin and also serves as the entry point for this plugin
It is important to fix the following:
  • Domain Path: The domain path folder does not exist ("/languages/")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short check of programming languages and file extensions; no executable files are allowed
No dangerous file extensions were detected607 lines of code in 9 files:
LanguageFilesBlank linesComment linesLines of code
PHP77978601
CSS1003
Markdown1103

PHP code Passed 2 tests

This is a short overview 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.25
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%
Functions44
▷ Named functions1636.36%
▷ Anonymous functions2863.64%
Constants2
▷ Global constants2100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

It is recommended to compress PNG files in your plugin to minimize bandwidth usage
1 PNG file occupies 0.01MB with 0.01MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
images/premiumwp-logo.png13.44KB5.59KB▼ 58.37%