99% product-options-index-for-woocommerce

Code Review | Product Options Index for Woocommerce

WordPress plugin Product Options Index for Woocommerce scored 99% from 54 tests.

About plugin

  • Plugin page: product-options-i...
  • Plugin version: 1.0.2
  • PHP compatiblity: 7.0+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0-5.8
  • WordPress version: 5.8.1
  • First release: Aug 26, 2020
  • Latest release: Jul 11, 2021
  • Number of updates: 12
  • Update frequency: every 26.7 days
  • Top authors: moztik (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 149 total downloads

Benchmarks

Plugin footprint Passed 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
This plugin's installer ran successfully

Server metrics [RAM: ▲0.03MB] [CPU: ▼142.77ms] Passed 4 tests

Server-side resources used by Product Options Index for Woocommerce
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /2.87 ▲0.0339.58 ▲1.70
Dashboard /wp-admin3.09 ▲0.0347.10 ▲1.98
Posts /wp-admin/edit.php3.15 ▲0.0353.65 ▲11.00
Add New Post /wp-admin/post-new.php5.46 ▲0.0293.30 ▼569.41
Media Library /wp-admin/upload.php3.04 ▲0.0334.89 ▼5.35

Server storage [IO: ▲0.73MB] [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: 18 new files
Database: no new tables, no new options

Browser metrics Passed 4 tests

Checking browser requirements for Product Options Index for Woocommerce
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,707 ▲12515.71 ▼0.119.39 ▲0.2352.46 ▼4.29
Dashboard /wp-admin2,977 ▲405.95 ▼0.01137.52 ▼17.02126.46 ▼0.79
Posts /wp-admin/edit.php2,743 ▲42.70 ▲0.0167.43 ▲0.1398.60 ▲3.48
Add New Post /wp-admin/post-new.php1,687 ▲418.74 ▼0.03404.94 ▲8.04102.74 ▼12.83
Media Library /wp-admin/upload.php1,811 ▲44.99 ▲0.01166.21 ▲15.09124.70 ▲6.38

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
The plugin uninstalled successfully, without leaving any zombie files or tables

Smoke tests Passed 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)
The smoke test was a success, however most plugin functionality was not tested

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
Everything seems fine, however this is by no means an exhaustive 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

Optimizations

Plugin configuration 86% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
These attributes need your attention:
  • Contributors: Contributors not specified
The official readme.txt might help

product-options-index-for-woocommerce/product-options-index.php 77% from 13 tests

"Product Options Index for Woocommerce" version 1.0.2's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
It is important to 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
  • Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("product-options-index-for-woocommerce.php" instead of "product-options-index.php")
  • Domain Path: The domain path is invalid: folder "/languages" does not exist

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short check of programming languages and file extensions; no executable files are allowed
There were no executable files found in this plugin348 lines of code in 5 files:
LanguageFilesBlank linesComment linesLines of code
PHP37091277
CSS210471

PHP code Passed 2 tests

An overview of cyclomatic complexity and code structure
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.19
Average class complexity17.00
▷ Minimum class complexity17.00
▷ Maximum class complexity17.00
Average method complexity3.00
▷ Minimum method complexity1.00
▷ Maximum method complexity15.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes2
▷ Abstract classes00.00%
▷ Concrete classes2100.00%
▷ Final classes00.00%
Methods16
▷ Static methods212.50%
▷ Public methods1487.50%
▷ Protected methods00.00%
▷ Private methods212.50%
Functions0
▷ Named functions00.00%
▷ Anonymous functions00.00%
Constants2
▷ Global constants2100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
No PNG images were found in this plugin