62% super-stage-wp

Code Review | Super Stage WP

WordPress plugin Super Stage WP scored62%from 54 tests.

About plugin

  • Plugin page: super-stage-wp
  • Plugin version: 1.0.1
  • PHP version: 7.4.16
  • WordPress compatibility: 3.9.14-6.2.2
  • WordPress version: 6.3.1
  • First release: Mar 6, 2023
  • Latest release: Jun 8, 2023
  • Number of updates: 8
  • Update frequency: every 12.0 days
  • Top authors: superstagewp (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /338 total downloads

Benchmarks

Plugin footprint 65% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
Install script ran successfully

Server metrics [RAM: ▲1.23MB] [CPU: ▼11.23ms] Passed 4 tests

An overview of server-side resources used by Super Stage WP
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /5.64 ▲2.1860.14 ▲18.19
Dashboard /wp-admin5.18 ▲1.8743.66 ▼3.33
Posts /wp-admin/edit.php5.18 ▲1.8242.42 ▼2.52
Add New Post /wp-admin/post-new.php5.18 ▼0.7141.81 ▼52.42
Media Library /wp-admin/upload.php5.18 ▲1.9548.01 ▲13.37
Settings /wp-admin/admin.php?page=wpss-settings-page5.1840.90
Super Stage WP /wp-admin/admin.php?page=wpss-main-page5.1843.93

Server storage [IO: ▲1.26MB] [DB: ▲0.02MB] Passed 3 tests

How much does this plugin use your filesystem and database?
There were no storage issued detected upon installing this plugin
Filesystem: 57 new files
Database: 8 new tables, 6 new options
New tables
wp_wpss_local_site_new_attachments
wp_wpss_backups
wp_wpss_processed_iterator
wp_wpss_options
wp_wpss_current_process
wp_wpss_inc_exc_contents
wp_wpss_processed_files
wp_wpss_activity_log
New WordPress options
widget_recent-posts
db_upgraded
theysaidso_admin_options
widget_theysaidso_widget
widget_recent-comments
can_compress_scripts

Browser metrics Passed 4 tests

An overview of browser requirements for Super Stage WP
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,894 ▲13313.91 ▼0.443.26 ▲1.5039.32 ▼6.42
Dashboard /wp-admin2,273 ▲965.87 ▲0.22103.25 ▲16.0586.42 ▲44.43
Posts /wp-admin/edit.php2,175 ▲752.80 ▲0.8245.33 ▲8.5332.22 ▼3.73
Add New Post /wp-admin/post-new.php1,593 ▲6522.59 ▼0.49606.50 ▼58.1735.41 ▼21.91
Media Library /wp-admin/upload.php1,463 ▲635.45 ▲1.28110.99 ▲6.1589.13 ▲43.45
Settings /wp-admin/admin.php?page=wpss-settings-page1,1452.6847.1433.35
Super Stage WP /wp-admin/admin.php?page=wpss-main-page1,0132.5438.9838.29

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
Please fix the following items
  • Uninstall procedure validation failed for this plugin
    • > User notice in wp-includes/functions.php+5905
    Function add_submenu_page was called incorrectly. The seventh parameter passed to add_submenu_page() should be numeric representing menu position. Please see Debugging in WordPress for more information. (This message was added in version 5.3.0.)
  • This plugin does not fully uninstall, leaving 6 options in the database
    • db_upgraded
    • widget_recent-comments
    • can_compress_scripts
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • widget_recent-posts

Smoke tests 25% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Almost there, just fix the following server-side errors
  • 2 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=wpss-main-page
    • > User notice in wp-includes/functions.php+5905
    Function add_submenu_page was called incorrectly. The seventh parameter passed to add_submenu_page() should be numeric representing menu position. Please see Debugging in WordPress for more information. (This message was added in version 5.3.0.)

SRP 0% from 2 tests

🔹 Tests weight: 20 | SRP (Single-Responsibility Principle) - PHP files must act as libraries and never output text or perform any action when accessed directly in a browser
The following issues need your attention
  • 1× PHP files output text when accessed directly:
    • > /wp-content/plugins/super-stage-wp/Staging/bridge/bridge.php
  • 9× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Fatal error
      Uncaught Error: Class 'WPSS_Base_Config' not found in wp-content/plugins/super-stage-wp/ExcludeOption/Config.php:3
    • > PHP Fatal error
      Uncaught Error: Class 'WPSS_Exclude' not found in wp-content/plugins/super-stage-wp/ExcludeOption/ExcludeOption.php:3
    • > PHP Fatal error
      Uncaught Error: Call to a member function is_allowed_to_copy_site_to_live() on null in wp-content/plugins/super-stage-wp/Staging/stage-to-live/views/super-stage-wp-staging.php:6
    • > PHP Fatal error
      Uncaught Error: Class 'WPSS_Base_Config' not found in wp-content/plugins/super-stage-wp/Staging/Config.php:3
    • > PHP Fatal error
      Uncaught Error: Class 'WPSS_Processed_Base' not found in wp-content/plugins/super-stage-wp/class-processed-iterator.php:22
    • > PHP Fatal error
      Uncaught Error: Class 'WPSS_Processed_Base' not found in wp-content/plugins/super-stage-wp/class-processed-files.php:22
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/super-stage-wp/views/wpss-settings.php:11
    • > PHP Notice
      Undefined variable: stage_to_live in wp-content/plugins/super-stage-wp/Staging/stage-to-live/views/super-stage-wp-staging.php on line 6
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_thickbox() in wp-content/plugins/super-stage-wp/views/wpss-main-page.php:59

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
Everything seems fine on the user side

Optimizations

Plugin configuration 93% from 29 tests

readme.txt Passed 16 tests

The readme.txt file uses markdown syntax to describe your plugin to the world
10 plugin tags: duplicate, db migration, migrate, backup, clone...

super-stage-wp/super-stage-wp.php 85% from 13 tests

The main PHP file in "Super Stage WP" ver. 1.0.1 adds more information about the plugin and also serves as the entry point for this plugin
It is important to fix the following:
  • Text Domain: Since WordPress version 4.6 the text domain is optional; if specified, it must be the same as the plugin slug
  • Domain Path: The domain path folder does not exist ("/languages")

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 detected29,743 lines of code in 49 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript72,8883,24917,233
PHP373,57168211,543
CSS437108966
SVG1001

PHP code Passed 2 tests

Analyzing cyclomatic complexity and code structure
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity
Average complexity per logical line of code0.35
Average class complexity49.19
▷ Minimum class complexity1.00
▷ Maximum class complexity206.00
Average method complexity3.13
▷ Minimum method complexity1.00
▷ Maximum method complexity27.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes32
▷ Abstract classes26.25%
▷ Concrete classes3093.75%
▷ Final classes00.00%
Methods709
▷ Static methods141.97%
▷ Public methods45363.89%
▷ Protected methods425.92%
▷ Private methods21430.18%
Functions126
▷ Named functions12498.41%
▷ Anonymous functions21.59%
Constants102
▷ Global constants9189.22%
▷ Class constants1110.78%
▷ Public constants11100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
1 PNG file occupies 0.00MB with 0.00MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
images/wpss-icon.png1.71KB0.94KB▼ 44.77%