84% woocommerce-chosen-variation-dropdowns

Code Review | WooCommerce Chosen Variation Dropdowns

WordPress plugin WooCommerce Chosen Variation Dropdowns scored 84% from 54 tests.

About plugin

  • Plugin page: woocommerce-chose...
  • Plugin version: 0.1
  • PHP version: 7.4.16
  • WordPress compatibility: 3.5-3.5
  • WordPress version: 6.3.1
  • First release: May 25, 2013
  • Latest release: May 25, 2013
  • Number of updates: 5
  • Update frequency: N/A
  • Top authors: Kloon (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 3,116 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
The plugin installed gracefully, with no errors

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

This is a short check of server-side resources used by WooCommerce Chosen Variation Dropdowns
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.46 ▲0.0039.44 ▲1.28
Dashboard /wp-admin3.31 ▲0.0044.98 ▼4.07
Posts /wp-admin/edit.php3.36 ▲0.0047.76 ▲0.43
Add New Post /wp-admin/post-new.php5.89 ▲0.0082.60 ▼8.29
Media Library /wp-admin/upload.php3.23 ▲0.0036.59 ▲0.18

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

Filesystem and database footprint
This plugin was installed successfully
Filesystem: 2 new files
Database: no new tables, 6 new options
New WordPress options
theysaidso_admin_options
db_upgraded
widget_recent-posts
widget_recent-comments
can_compress_scripts
widget_theysaidso_widget

Browser metrics Passed 4 tests

WooCommerce Chosen Variation Dropdowns: an overview of browser usage
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,800 ▲6513.57 ▼0.831.75 ▲0.0540.96 ▼4.60
Dashboard /wp-admin2,209 ▲215.87 ▲0.99106.40 ▼6.9838.89 ▼0.99
Posts /wp-admin/edit.php2,089 ▼01.99 ▼0.0139.01 ▼2.7635.08 ▼3.38
Add New Post /wp-admin/post-new.php1,519 ▼1123.24 ▲4.90644.99 ▲33.9451.40 ▼3.07
Media Library /wp-admin/upload.php1,385 ▼04.24 ▲0.10100.44 ▼6.5642.36 ▼2.68

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
You still need to fix the following
  • Zombie WordPress options were found after uninstall: 6 options
    • db_upgraded
    • widget_recent-posts
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • can_compress_scripts
    • widget_recent-comments

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
Almost there! Just fix the following items
  • 1× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function apply_filters() in wp-content/plugins/woocommerce-chosen-variation-dropdowns/woocommerce-chosen-variation-dropdowns.php:18

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
No browser issues were found

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

Don't ignore readme.txt as it is the file that instructs WordPress.org on how to present your plugin to the world
5 plugin tags: chosen, products, woocommerce, dropdown, ecommerce

woocommerce-chosen-variation-dropdowns/woocommerce-chosen-variation-dropdowns.php Passed 13 tests

The main PHP script in "WooCommerce Chosen Variation Dropdowns" version 0.1 is automatically included on every request by WordPress
76 characters long description:
Transform the variation dropdowns on your product pages to Chosen dropdowns.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are considered dangerous and should not be included with any WordPress plugin
Everything looks great! No dangerous files found in this plugin57 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code
PHP1111557

PHP code Passed 2 tests

Analyzing logical lines of code, cyclomatic complexity, and other code metrics
This plugin has no cyclomatic complexity problems
Cyclomatic complexity
Average complexity per logical line of code0.45
Average class complexity9.00
▷ Minimum class complexity9.00
▷ Maximum class complexity9.00
Average method complexity3.67
▷ Minimum method complexity1.00
▷ Maximum method complexity7.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods3
▷ Static methods00.00%
▷ Public methods3100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions0
▷ Named functions00.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Often times overlooked, PNG files can occupy unnecessary space in your plugin
There were not PNG files found in your plugin