84% warehouse-popups-woocommerce

Code Review | Woocommerce Multi Warehouses - Location Based Inventory Management

WordPress plugin Woocommerce Multi Warehouses - Location Based Inventory Management scored 84% from 54 tests.

About plugin

  • Plugin page: warehouse-popups-...
  • Plugin version: 2.0.4
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0.1-5.6
  • WordPress version: 6.3.1
  • First release: Aug 30, 2018
  • Latest release: Sep 3, 2021
  • Number of updates: 128
  • Update frequency: every 8.6 days
  • Top authors: joeleem0n (100%)

Code review

54 tests

User reviews

4 reviews

Install metrics

60+ active / 7,161 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
The plugin installed gracefully, with no errors

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

An overview of server-side resources used by Woocommerce Multi Warehouses - Location Based Inventory Management
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.46 ▲0.0043.34 ▼3.84
Dashboard /wp-admin3.31 ▲0.0048.21 ▼4.05
Posts /wp-admin/edit.php3.36 ▲0.0050.98 ▼1.56
Add New Post /wp-admin/post-new.php5.89 ▲0.00104.64 ▲10.58
Media Library /wp-admin/upload.php3.23 ▲0.0037.40 ▼0.53

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

Analyzing filesystem and database footprints of this plugin
There were no storage issued detected upon installing this plugin
Filesystem: 116 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-posts
theysaidso_admin_options
db_upgraded
widget_recent-comments
widget_theysaidso_widget
can_compress_scripts

Browser metrics Passed 4 tests

Checking browser requirements for Woocommerce Multi Warehouses - Location Based Inventory Management
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,800 ▲1113.28 ▼0.021.73 ▲0.0544.57 ▲6.25
Dashboard /wp-admin2,206 ▼04.86 ▲0.05101.95 ▼1.0537.85 ▼1.72
Posts /wp-admin/edit.php2,092 ▼02.00 ▼0.0137.68 ▼2.1133.97 ▼6.08
Add New Post /wp-admin/post-new.php1,535 ▲223.49 ▲0.26587.15 ▼109.5748.98 ▼8.05
Media Library /wp-admin/upload.php1,388 ▲34.21 ▲0.0295.38 ▼5.1441.81 ▲0.17

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

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

Smoke tests 75% from 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 50% from 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
Please fix the following
  • 44× GET requests to PHP files have triggered server-side errors or warnings (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Class 'GeoIp2\\Model\\AbstractModel' not found in wp-content/plugins/warehouse-popups-woocommerce/public/vendor/geoip2/geoip2/src/Model/Domain.php:19
    • > PHP Fatal error
      Uncaught Error: Class 'GeoIp2\\Record\\AbstractRecord' not found in wp-content/plugins/warehouse-popups-woocommerce/public/vendor/geoip2/geoip2/src/Record/Postal.php:20
    • > PHP Fatal error
      Uncaught Error: Class 'GeoIp2\\Exception\\HttpException' not found in wp-content/plugins/warehouse-popups-woocommerce/public/vendor/geoip2/geoip2/src/Exception/InvalidRequestException.php:9
    • > PHP Fatal error
      Uncaught Error: Class 'GeoIp2\\Model\\AbstractModel' not found in wp-content/plugins/warehouse-popups-woocommerce/public/vendor/geoip2/geoip2/src/Model/Isp.php:25
    • > PHP Fatal error
      Uncaught Error: Class 'MaxMind\\Exception\\InvalidRequestException' not found in wp-content/plugins/warehouse-popups-woocommerce/public/vendor/maxmind/web-service-common/src/Exception/PermissionRequiredException.php:8
    • > PHP Fatal error
      Uncaught Error: Class 'GeoIp2\\Record\\AbstractPlaceRecord' not found in wp-content/plugins/warehouse-popups-woocommerce/public/vendor/geoip2/geoip2/src/Record/Subdivision.php:29
    • > PHP Fatal error
      Uncaught Error: Class 'GeoIp2\\Exception\\GeoIp2Exception' not found in wp-content/plugins/warehouse-popups-woocommerce/public/vendor/geoip2/geoip2/src/Exception/AddressNotFoundException.php:8
    • > PHP Fatal error
      Uncaught Error: Class 'GeoIp2\\Record\\AbstractPlaceRecord' not found in wp-content/plugins/warehouse-popups-woocommerce/public/vendor/geoip2/geoip2/src/Record/City.php:23
    • > PHP Fatal error
      Uncaught Error: Class 'MaxMind\\Exception\\InvalidRequestException' not found in wp-content/plugins/warehouse-popups-woocommerce/public/vendor/maxmind/web-service-common/src/Exception/InsufficientFundsException.php:8
    • > PHP Fatal error
      Uncaught Error: Class 'GeoIp2\\Record\\AbstractRecord' not found in wp-content/plugins/warehouse-popups-woocommerce/public/vendor/geoip2/geoip2/src/Record/MaxMind.php:13

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
Everything seems fine on the user side

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 88% from 16 tests

Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
Attributes that need to be fixed: You can look at the official readme.txt

warehouse-popups-woocommerce/warehouse-popups-woocommerce.php Passed 13 tests

"Woocommerce Multi Warehouses - Location Based Inventory Management" version 2.0.4's main PHP file describes plugin functionality and also serves as the entry point to any WordPress functionality
127 characters long description:
Manages product inventory, currency, prices, & payments across multiple warehouses with a single site WP + Woocommerce install.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short review of files and their extensions; it is not recommended to include executable files
No dangerous file extensions were detected8,634 lines of code in 100 files:
LanguageFilesBlank linesComment linesLines of code
PHP801,0122,2946,433
Markdown73700875
C19718589
JSON500384
JavaScript24873226
CSS27847
Bourne Shell120040
m418032
C/C++ Header14128

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.46
Average class complexity12.81
▷ Minimum class complexity1.00
▷ Maximum class complexity266.00
Average method complexity3.78
▷ Minimum method complexity1.00
▷ Maximum method complexity90.00
Code structure
Namespaces13
Interfaces2
Traits0
Classes60
▷ Abstract classes35.00%
▷ Concrete classes5795.00%
▷ Final classes00.00%
Methods263
▷ Static methods6223.57%
▷ Public methods19574.14%
▷ Protected methods10.38%
▷ Private methods6725.48%
Functions12
▷ Named functions758.33%
▷ Anonymous functions541.67%
Constants21
▷ Global constants314.29%
▷ Class constants1885.71%
▷ Public constants18100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
No PNG files were detected