99% extra-product-options-for-woocommerce

Code Review | Extra Product Options for WooCommerce

WordPress plugin Extra Product Options for WooCommerce scored 99% from 54 tests.

About plugin

  • Plugin page: extra-product-opt...
  • Plugin version:
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0-5.8.1
  • WordPress version: 5.8.1
  • First release: Oct 25, 2020
  • Latest release: Nov 16, 2021
  • Number of updates: 36
  • Update frequency: every 10.9 days
  • Top authors: actpro (100%)

Code review

54 tests

User reviews

2 reviews

Install metrics

700+ active / 7,732 total downloads


Plugin footprint Passed 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
The plugin installed successfully, without throwing any errors or notices

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

An overview of server-side resources used by Extra Product Options for WooCommerce
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /2.83 ▲0.1229.50 ▲8.37
Dashboard /wp-admin3.06 ▲0.0043.15 ▲1.64
Posts /wp-admin/edit.php3.11 ▲0.0043.52 ▲1.19
Add New Post /wp-admin/post-new.php5.42 ▼0.0281.54 ▼569.62
Media Library /wp-admin/upload.php3.00 ▲0.0032.03 ▲2.27

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

Input-output and database impact of this plugin
This plugin installed successfully
Filesystem: 31 new files
Database: no new tables, no new options

Browser metrics Passed 4 tests

An overview of browser requirements for Extra Product Options for WooCommerce
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,679 ▲8316.23 ▲0.679.90 ▲0.1745.28 ▼3.45
Dashboard /wp-admin2,970 ▲365.89 ▼0.10134.73 ▼4.19116.60 ▲2.34
Posts /wp-admin/edit.php2,739 ▼02.71 ▼0.0067.63 ▲0.3592.35 ▼0.18
Add New Post /wp-admin/post-new.php1,683 ▼1,95318.44 ▲3.50357.43 ▼89.56119.00 ▲10.68
Media Library /wp-admin/upload.php1,807 ▼35.04 ▼0.01144.04 ▼8.86125.82 ▼0.98

Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] Passed 4 tests

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
Uninstaller ran successfully

Smoke tests Passed 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
The smoke test was a success, however most plugin functionality was not tested

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
Congratulations! This plugin passed the SRP test

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
Everything seems fine on the user side


Plugin configuration 93% from 29 tests

readme.txt Passed 16 tests

The readme.txt file is an important file in your plugin as it is parsed by WordPress.org to prepare the public listing of your plugin
4 plugin tags: woocommerce extra product options, product options, woocommerce extra product fields, woocommerce product addons

extra-product-options-for-woocommerce/extra-product-options-for-woocommerce.php 85% from 13 tests

This is the main PHP file of "Extra Product Options for WooCommerce" version, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
Please make the necessary changes and fix the following:
  • Requires at least: Required version must be the same as the one declared in readme.txt ("3.8" instead of "3.0")
  • Description: If Twitter did it, so should we! Keep the description under 140 characters (currently 201 characters long)

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
Success! There were no dangerous files found in this plugin7,778 lines of code in 22 files:
LanguageFilesBlank linesComment linesLines of code
PO File1113151244

PHP code Passed 2 tests

Analyzing cyclomatic complexity and code structure
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.40
Average class complexity44.71
▷ Minimum class complexity1.00
▷ Maximum class complexity138.00
Average method complexity4.87
▷ Minimum method complexity1.00
▷ Maximum method complexity39.00
Code structure
▷ Abstract classes00.00%
▷ Concrete classes7100.00%
▷ Final classes00.00%
▷ Static methods1417.72%
▷ Public methods7594.94%
▷ Protected methods33.80%
▷ Private methods11.27%
▷ Named functions52100.00%
▷ Anonymous functions00.00%
▷ Global constants12100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Using a strong compression for your PNG files is a great way to speed-up your plugin
6 PNG files occupy 0.29MB with 0.15MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
assets/images/cart_field_option.png33.82KB13.36KB▼ 60.49%
assets/images/icon-128x128.png5.79KB2.60KB▼ 55.12%
assets/images/admin_field_option.png60.05KB32.26KB▼ 46.27%
assets/images/front_field_option.png160.00KB55.40KB▼ 65.37%
assets/images/admin_order_detail.png13.19KB7.98KB▼ 39.51%