90% shipment-addon-for-woocommerce

Code Review | Shipment addon for WooCommerce

WordPress plugin Shipment addon for WooCommerce scored90%from 54 tests.

About plugin

  • Plugin page: shipment-addon-fo...
  • Plugin version: 1.0.1
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.7-6.0
  • WordPress version: 6.3.1
  • First release: May 17, 2022
  • Latest release: Jun 10, 2022
  • Number of updates: 4
  • Update frequency: every 3.8 days
  • Top authors: hitstacks (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /205 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
The plugin installed successfully, without throwing any errors or notices

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

Analyzing server-side resources used by Shipment addon for WooCommerce
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0037.87 ▼4.83
Dashboard /wp-admin3.31 ▼0.0444.05 ▼17.25
Posts /wp-admin/edit.php3.36 ▲0.0046.18 ▲2.08
Add New Post /wp-admin/post-new.php5.89 ▲0.0092.52 ▲3.71
Media Library /wp-admin/upload.php3.23 ▲0.0034.40 ▼1.45

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

Input-output and database impact of this plugin
There were no storage issued detected upon installing this plugin
Filesystem: 8 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

Shipment addon for WooCommerce: an overview of browser usage
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,800 ▲6513.67 ▼0.741.75 ▼0.4042.96 ▼7.29
Dashboard /wp-admin2,209 ▲185.88 ▲1.02106.02 ▼2.4341.69 ▼5.21
Posts /wp-admin/edit.php2,089 ▼02.03 ▲0.0239.40 ▲1.7233.64 ▼2.00
Add New Post /wp-admin/post-new.php1,514 ▼2317.67 ▼0.67635.68 ▲29.0252.94 ▼3.93
Media Library /wp-admin/upload.php1,391 ▲34.18 ▼0.0499.92 ▲0.8442.69 ▼6.14

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
You still need to fix the following
  • The uninstall procedure has failed, leaving 6 options in the database
    • widget_recent-comments
    • widget_recent-posts
    • theysaidso_admin_options
    • db_upgraded
    • can_compress_scripts
    • widget_theysaidso_widget

Smoke tests Passed 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 Passed 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
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
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

You should put a lot of thought into formatting readme.txt as it is used by WordPress.org to prepare the public listing of your plugin
3 plugin tags: addon, woocommerce, shipping

shipment-addon-for-woocommerce/shipment-addon-for-woocommerce.php 92% from 13 tests

"Shipment addon for WooCommerce" version 1.0.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: If you choose to specify the text domain, it must be the same as the plugin slug; optional since WordPress version 4.6

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 detected519 lines of code in 7 files:
LanguageFilesBlank linesComment linesLines of code
PHP594158517
CSS1061
JavaScript1061

PHP code Passed 2 tests

A short review of 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 complexity18.00
▷ Minimum class complexity4.00
▷ Maximum class complexity32.00
Average method complexity3.12
▷ Minimum method complexity1.00
▷ Maximum method complexity23.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes2
▷ Abstract classes00.00%
▷ Concrete classes2100.00%
▷ Final classes00.00%
Methods16
▷ Static methods212.50%
▷ Public methods16100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions1
▷ Named functions1100.00%
▷ Anonymous functions00.00%
Constants2
▷ Global constants2100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
There were not PNG files found in your plugin