84% mw-wp-hacks

Code Review | MW WP Hacks

WordPress plugin MW WP Hacks scored84%from 54 tests.

About plugin

  • Plugin page: mw-wp-hacks
  • Plugin version: 1.4.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.6-4.1.0
  • WordPress version: 6.3.1
  • First release: Nov 4, 2013
  • Latest release: Feb 18, 2015
  • Number of updates: 69
  • Update frequency: every 6.8 days
  • Top authors: inc2734 (100%)

Code review

54 tests

User reviews

2 reviews

Install metrics

70+ active /2,990 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
The plugin installed gracefully, with no errors

Server metrics [RAM: ▲0.56MB] [CPU: ▲2.25ms] Passed 4 tests

A check of server-side resources used by MW WP Hacks
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /4.02 ▲0.5654.28 ▲10.90
Dashboard /wp-admin3.89 ▲0.5572.07 ▲1.83
Posts /wp-admin/edit.php3.95 ▲0.5958.10 ▲6.90
Add New Post /wp-admin/post-new.php6.47 ▲0.59101.19 ▼9.75
Media Library /wp-admin/upload.php3.80 ▲0.5746.36 ▲10.02

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

Analyzing filesystem and database footprints of this plugin
No storage issues were detected
Filesystem: 30 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-posts
db_upgraded
widget_recent-comments
theysaidso_admin_options
widget_theysaidso_widget
can_compress_scripts

Browser metrics Passed 4 tests

An overview of browser requirements for MW WP Hacks
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,959 ▲19814.34 ▼0.051.82 ▲0.2142.48 ▼0.33
Dashboard /wp-admin2,355 ▲1786.18 ▲0.49122.91 ▲34.2342.22 ▲4.79
Posts /wp-admin/edit.php2,283 ▲1833.32 ▲1.3348.06 ▲13.1335.37 ▲0.91
Add New Post /wp-admin/post-new.php1,580 ▲5423.16 ▼0.10634.79 ▼56.3040.95 ▼13.15
Media Library /wp-admin/upload.php1,426 ▲264.15 ▼0.0786.45 ▼22.7144.82 ▲2.75

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
It is recommended to fix the following
  • Zombie WordPress options detected upon uninstall: 6 options
    • theysaidso_admin_options
    • can_compress_scripts
    • db_upgraded
    • widget_recent-posts
    • widget_theysaidso_widget
    • widget_recent-comments

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
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
  • 14× GET requests to PHP files trigger server-side errors or Error 500 responses (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Class 'MW_WP_Hacks_Abstract_Setting' not found in wp-content/plugins/mw-wp-hacks/classes/class.setting-ogp.php:13
    • > PHP Fatal error
      Uncaught Error: Class 'MW_WP_Hacks_Abstract_Setting' not found in wp-content/plugins/mw-wp-hacks/classes/class.setting-description.php:13
    • > PHP Fatal error
      Uncaught Error: Class 'MW_WP_Hacks_Abstract_Setting' not found in wp-content/plugins/mw-wp-hacks/classes/class.setting-social.php:13
    • > PHP Fatal error
      Uncaught Error: Class 'MW_WP_Hacks_Abstract_Setting' not found in wp-content/plugins/mw-wp-hacks/classes/class.setting-cpt-archive-posts.php:13
    • > PHP Fatal error
      Uncaught Error: Class 'MW_WP_Hacks_Abstract_Setting' not found in wp-content/plugins/mw-wp-hacks/classes/class.setting-script.php:13
    • > PHP Fatal error
      Uncaught Error: Class 'MW_WP_Hacks_Abstract_Setting' not found in wp-content/plugins/mw-wp-hacks/classes/class.setting-thumbnail.php:13
    • > PHP Fatal error
      Uncaught Error: Call to undefined function register_uninstall_hook() in wp-content/plugins/mw-wp-hacks/mw-wp-hacks.php:32
    • > PHP Fatal error
      Uncaught Error: Class 'MW_WP_Hacks_Abstract_Setting' not found in wp-content/plugins/mw-wp-hacks/classes/class.setting-widget.php:13
    • > PHP Fatal error
      Uncaught Error: Class 'MW_WP_Hacks_Abstract_Setting' not found in wp-content/plugins/mw-wp-hacks/classes/class.setting-feed.php:13
    • > PHP Fatal error
      Uncaught Error: Class 'MW_WP_Hacks_Abstract_Setting' not found in wp-content/plugins/mw-wp-hacks/classes/class.setting-general.php:13

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
No browser issues were found

Optimizations

Plugin configuration 97% from 29 tests

readme.txt 94% from 16 tests

It's important to format your readme.txt file correctly as it is parsed for the public listing of your plugin
Attributes that require attention:
  • Plugin Name: Please replace "Plugin Name" with the name of your plugin on the first line ( === mw-wp-hacks === )
You can look at the official readme.txt

mw-wp-hacks/mw-wp-hacks.php Passed 13 tests

"MW WP Hacks" version 1.4.0's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
60 characters long description:
MW WP Hacks is plugin to help with development in WordPress.

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
Everything looks great! No dangerous files found in this plugin3,056 lines of code in 27 files:
LanguageFilesBlank linesComment linesLines of code
PHP212389522,736
PO File16468159
JavaScript28969
Sass15053
CSS23639

PHP code Passed 2 tests

This is a very shot review of cyclomatic complexity and code structure
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.38
Average class complexity18.29
▷ Minimum class complexity1.00
▷ Maximum class complexity121.00
Average method complexity3.33
▷ Minimum method complexity1.00
▷ Maximum method complexity25.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes21
▷ Abstract classes14.76%
▷ Concrete classes2095.24%
▷ Final classes00.00%
Methods160
▷ Static methods85.00%
▷ Public methods9660.00%
▷ Protected methods5735.62%
▷ Private methods74.38%
Functions0
▷ Named functions00.00%
▷ Anonymous functions00.00%
Constants4
▷ Global constants125.00%
▷ Class constants375.00%
▷ Public constants3100.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
There are no PNG files in this plugin