84% webshippy-dynamic-shipping

Code Review | Webshippy Dynamic Shipping

WordPress plugin Webshippy Dynamic Shipping scored84%from 54 tests.

About plugin

  • Plugin page: webshippy-dynamic...
  • Plugin version: 1.2.1
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0-5.7.2
  • WordPress version: 6.3.1
  • First release: Jun 15, 2021
  • Latest release: Dec 3, 2021
  • Number of updates: 15
  • Update frequency: every 11.5 days
  • Top authors: webshippy (100%)

Code review

54 tests

User reviews

1 review

Install metrics

30+ active /858 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
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▼0.01MB] [CPU: ▼3.73ms] Passed 4 tests

This is a short check of server-side resources used by Webshippy Dynamic Shipping
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.46 ▲0.0037.19 ▼0.55
Dashboard /wp-admin3.31 ▼0.0444.42 ▼15.35
Posts /wp-admin/edit.php3.36 ▲0.0047.83 ▲2.74
Add New Post /wp-admin/post-new.php5.89 ▲0.0095.96 ▲3.34
Media Library /wp-admin/upload.php3.23 ▲0.0032.93 ▼1.76

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

Analyzing filesystem and database footprints of this plugin
This plugin installed successfully
Filesystem: 20 new files
Database: no new tables, 6 new options
New WordPress options
db_upgraded
widget_recent-comments
theysaidso_admin_options
can_compress_scripts
widget_recent-posts
widget_theysaidso_widget

Browser metrics Passed 4 tests

Webshippy Dynamic Shipping: an overview of browser usage
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,825 ▲5413.26 ▼1.131.73 ▼0.0139.25 ▼2.85
Dashboard /wp-admin2,203 ▲115.82 ▲0.9097.99 ▼6.8537.72 ▼4.16
Posts /wp-admin/edit.php2,092 ▲32.06 ▲0.0539.35 ▲4.8836.36 ▲1.49
Add New Post /wp-admin/post-new.php1,533 ▲1422.83 ▼0.55601.25 ▼61.6256.97 ▼13.55
Media Library /wp-admin/upload.php1,388 ▼04.19 ▼0.0295.83 ▲1.8641.52 ▲1.10

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
Please fix the following items
  • This plugin does not fully uninstall, leaving 6 options in the database
    • widget_recent-posts
    • theysaidso_admin_options
    • can_compress_scripts
    • widget_recent-comments
    • db_upgraded
    • widget_theysaidso_widget

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Everything seems fine, however this is by no means an exhaustive test

SRP 50% 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
The following issues need your attention
  • 3× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function apply_filters() in wp-content/plugins/webshippy-dynamic-shipping/admin/class-ws-gls-shipping-method.php:14
    • > PHP Fatal error
      Uncaught Error: Call to undefined function apply_filters() in wp-content/plugins/webshippy-dynamic-shipping/admin/class-ws-prime-shipping-method.php:14
    • > PHP Fatal error
      Uncaught Error: Call to undefined function apply_filters() in wp-content/plugins/webshippy-dynamic-shipping/admin/class-ws-prio-nextday-shipping-method.php:14

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

Don't ignore readme.txt as it is the file that instructs WordPress.org on how to present your plugin to the world
2 plugin tags: shipping, woocommerce

webshippy-dynamic-shipping/webshippy-dynamic-shipping.php 92% from 13 tests

"Webshippy Dynamic Shipping" version 1.2.1's main PHP file describes plugin functionality and also serves as the entry point to any WordPress functionality
Please make the necessary changes and fix the following:
  • Text Domain: You no longer need to specify the text domain since WordPress 4.6; it must be the same as the plugin slug

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short glimpse at programming languages used with this plugin and a check that no dangerous files are present
Good job! No executable or dangerous file extensions detected485 lines of code in 14 files:
LanguageFilesBlank linesComment linesLines of code
PHP14180632485

PHP code Passed 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity
Average complexity per logical line of code0.18
Average class complexity3.09
▷ Minimum class complexity1.00
▷ Maximum class complexity16.00
Average method complexity1.52
▷ Minimum method complexity1.00
▷ Maximum method complexity7.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes11
▷ Abstract classes00.00%
▷ Concrete classes11100.00%
▷ Final classes00.00%
Methods44
▷ Static methods24.55%
▷ Public methods3477.27%
▷ Protected methods511.36%
▷ Private methods511.36%
Functions9
▷ Named functions9100.00%
▷ Anonymous functions00.00%
Constants1
▷ Global constants1100.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
No PNG images were found in this plugin