89% master-shipping-for-woocommerce

Code Review | Master Shipping for WooCommerce

WordPress plugin Master Shipping for WooCommerce scored89%from 54 tests.

About plugin

  • Plugin page: master-shipping-f...
  • Plugin version: 1.0.1
  • PHP compatiblity: 7.0+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.5-6.2
  • WordPress version: 6.3.1
  • First release: May 3, 2022
  • Latest release: Apr 8, 2023
  • Number of updates: 4
  • Update frequency: every 85.0 days
  • Top authors: wsjrcatarri (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /279 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
Installer ran successfully

Server metrics [RAM: ▲0.00MB] [CPU: ▼0.40ms] Passed 4 tests

Server-side resources used by Master Shipping for WooCommerce
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.46 ▲0.0036.74 ▼2.16
Dashboard /wp-admin3.31 ▲0.0044.20 ▼4.91
Posts /wp-admin/edit.php3.36 ▲0.0046.40 ▲2.59
Add New Post /wp-admin/post-new.php5.89 ▲0.0091.22 ▲4.43
Media Library /wp-admin/upload.php3.23 ▲0.0034.93 ▲2.87

Server storage [IO: ▲0.30MB] [DB: ▲0.07MB] Passed 3 tests

Filesystem and database footprint
This plugin was installed successfully
Filesystem: 19 new files
Database: no new tables, 6 new options
New WordPress options
widget_theysaidso_widget
can_compress_scripts
widget_recent-comments
db_upgraded
theysaidso_admin_options
widget_recent-posts

Browser metrics Passed 4 tests

An overview of browser requirements for Master Shipping for WooCommerce
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,800 ▲5413.55 ▼0.821.65 ▼0.0242.39 ▼1.16
Dashboard /wp-admin2,209 ▲214.84 ▼1.04109.14 ▲6.7642.06 ▲2.69
Posts /wp-admin/edit.php2,089 ▲32.01 ▼0.0339.96 ▲4.8634.93 ▲3.40
Add New Post /wp-admin/post-new.php1,542 ▲2323.42 ▲0.19578.39 ▼90.0264.25 ▲11.69
Media Library /wp-admin/upload.php1,388 ▼04.17 ▼0.0297.45 ▲1.8642.34 ▲0.97

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

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
Please fix the following items
  • This plugin does not fully uninstall, leaving 6 options in the database
    • widget_theysaidso_widget
    • widget_recent-comments
    • can_compress_scripts
    • widget_recent-posts
    • theysaidso_admin_options
    • db_upgraded

Smoke tests Passed 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 Passed 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
Looking good! No server-side errors or output on direct access of PHP files

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
There were no browser issues found

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file is important because it is parsed by WordPress.org for the public listing of your plugin
Attributes that require attention: The official readme.txt might help

master-shipping-for-woocommerce/wcmaster-shipping.php 85% from 13 tests

"Master Shipping for WooCommerce" version 1.0.1's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
The following require your attention:
  • Text Domain: The text domain is optional since WordPress version 4.6; if you do specify it, it must be the same as the plugin slug
  • Main file name: Name the main plugin file the same as the plugin slug ("master-shipping-for-woocommerce.php" instead of "wcmaster-shipping.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | There should be no dangerous file extensions present in any WordPress plugin
No dangerous file extensions were detected1,963 lines of code in 15 files:
LanguageFilesBlank linesComment linesLines of code
PHP92303111,242
CSS2238458
PO File16168134
JavaScript234128
JSON1001

PHP code Passed 2 tests

Analyzing logical lines of code, cyclomatic complexity, and other code metrics
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.49
Average class complexity33.86
▷ Minimum class complexity1.00
▷ Maximum class complexity117.00
Average method complexity5.00
▷ Minimum method complexity1.00
▷ Maximum method complexity48.00
Code structure
Namespaces1
Interfaces0
Traits1
Classes6
▷ Abstract classes00.00%
▷ Concrete classes6100.00%
▷ Final classes00.00%
Methods45
▷ Static methods817.78%
▷ Public methods45100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions10
▷ Named functions220.00%
▷ Anonymous functions880.00%
Constants2
▷ Global constants2100.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
There are no PNG files in this plugin