89% micro-warehouse-shipping-for-woocommerce

Code Review | Micro-warehouse Shipping Quotes

WordPress plugin Micro-warehouse Shipping Quotes scored89%from 54 tests.

About plugin

  • Plugin page: micro-warehouse-s...
  • Plugin version: 1.0.4
  • PHP version: 7.4.16
  • WordPress compatibility: 6.4-6.3
  • WordPress version: 6.3.1
  • First release: Nov 9, 2021
  • Latest release: Aug 15, 2023
  • Number of updates: 9
  • Update frequency: every 72.2 days
  • Top authors: enituretechnology (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /433 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
The plugin installed successfully, without throwing any errors or notices

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

Analyzing server-side resources used by Micro-warehouse Shipping Quotes
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.48 ▲0.0235.58 ▼7.97
Dashboard /wp-admin3.32 ▼0.0344.12 ▼18.94
Posts /wp-admin/edit.php3.43 ▲0.0747.25 ▲7.15
Add New Post /wp-admin/post-new.php5.90 ▲0.0188.04 ▼14.94
Media Library /wp-admin/upload.php3.24 ▲0.0134.91 ▲2.60

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

How much does this plugin use your filesystem and database?
No storage issues were detected
Filesystem: 6 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-posts
widget_recent-comments
db_upgraded
can_compress_scripts
theysaidso_admin_options
widget_theysaidso_widget

Browser metrics Passed 4 tests

Micro-warehouse Shipping Quotes: an overview of browser usage
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,802 ▲5613.23 ▼1.381.58 ▼0.1542.41 ▼4.12
Dashboard /wp-admin2,208 ▲204.87 ▼1.04113.23 ▲9.2339.47 ▲0.99
Posts /wp-admin/edit.php2,094 ▲52.12 ▲0.1240.17 ▼1.4935.57 ▼1.47
Add New Post /wp-admin/post-new.php1,539 ▲1118.35 ▲0.05633.83 ▲29.6051.05 ▼11.55
Media Library /wp-admin/upload.php1,384 ▼44.24 ▲0.0697.41 ▲0.1541.01 ▼3.95

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
The following items require your attention
  • Zombie WordPress options were found after uninstall: 6 options
    • db_upgraded
    • widget_recent-posts
    • can_compress_scripts
    • theysaidso_admin_options
    • widget_recent-comments
    • widget_theysaidso_widget

Smoke tests Passed 4 tests

Server-side errors Passed 1 test

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

SRP Passed 2 tests

🔹 Tests weight: 20 | The single-responsibility principle: PHP files have to remain inert when accessed directly, throwing no errors and performing no actions
No output text or server-side errors detected on direct access of PHP files

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, but this is not an exhaustive test

Optimizations

Plugin configuration 86% 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 need to be fixed:
  • Tags: Please delete some tags, you are using 17 tag instead of maximum 10
The official readme.txt is a good inspiration

micro-warehouse-shipping-for-woocommerce/micro-warehouse-shipping.php 77% from 13 tests

The principal PHP file in "Micro-warehouse Shipping Quotes" v. 1.0.4 is loaded by WordPress automatically on each request
It is important to fix the following:
  • 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
  • Requires at least: The required version number must match the one declared in readme.txt ("6.2" instead of "6.4")
  • Main file name: It is recommended to name the main PHP file as the plugin slug ("micro-warehouse-shipping-for-woocommerce.php" instead of "micro-warehouse-shipping.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | An overview of files in this plugin; executable files are not allowed
Success! There were no dangerous files found in this plugin429 lines of code in 4 files:
LanguageFilesBlank linesComment linesLines of code
PHP351101359
CSS113070

PHP code Passed 2 tests

Analyzing logical lines of code, cyclomatic complexity, and other code metrics
There were no cyclomatic complexity issued detected
Cyclomatic complexity
Average complexity per logical line of code0.58
Average class complexity53.00
▷ Minimum class complexity23.00
▷ Maximum class complexity83.00
Average method complexity7.50
▷ Minimum method complexity1.00
▷ Maximum method complexity47.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes2
▷ Abstract classes00.00%
▷ Concrete classes2100.00%
▷ Final classes00.00%
Methods16
▷ Static methods00.00%
▷ Public methods16100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions1
▷ Named functions1100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.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