84% variations-select-menu-for-woocommerce

Code Review | Variations Select Menu For Woocommerce

WordPress plugin Variations Select Menu For Woocommerce scored 84% from 54 tests.

About plugin

  • Plugin page: variations-select...
  • Plugin version: 1.1
  • PHP version: 7.4.16
  • WordPress compatibility: 4.6-4.9
  • WordPress version: 6.3.1
  • First release: Mar 17, 2018
  • Latest release: Mar 17, 2018
  • Number of updates: 6
  • Update frequency: every 0.5 days
  • Top authors: dadodd (100%)

Code review

54 tests

User reviews

1 review

Install metrics

20+ active / 842 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
The plugin installed gracefully, with no errors

Server metrics [RAM: ▲0.01MB] [CPU: ▼2.58ms] Passed 4 tests

An overview of server-side resources used by Variations Select Menu For Woocommerce
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0136.75 ▼6.92
Dashboard /wp-admin3.31 ▲0.0143.14 ▼6.02
Posts /wp-admin/edit.php3.36 ▲0.0147.70 ▲2.18
Add New Post /wp-admin/post-new.php5.89 ▲0.0196.65 ▲0.43
Media Library /wp-admin/upload.php3.24 ▲0.0137.61 ▲3.32

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

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

Browser metrics Passed 4 tests

Variations Select Menu For Woocommerce: an overview of browser usage
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,802 ▲6713.28 ▼1.091.62 ▼0.0939.23 ▼11.94
Dashboard /wp-admin2,203 ▲155.79 ▲0.8896.57 ▼22.4636.83 ▼6.12
Posts /wp-admin/edit.php2,092 ▲31.99 ▼0.0138.45 ▲0.8233.83 ▼1.09
Add New Post /wp-admin/post-new.php1,534 ▲123.18 ▼0.03649.64 ▼12.9254.05 ▼4.26
Media Library /wp-admin/upload.php1,388 ▼04.31 ▲0.0991.22 ▼4.7641.08 ▼1.44

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
It is recommended to fix the following
  • The uninstall procedure has failed, leaving 6 options in the database
    • can_compress_scripts
    • widget_recent-comments
    • widget_theysaidso_widget
    • widget_recent-posts
    • db_upgraded
    • theysaidso_admin_options

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

SRP 50% from 2 tests

🔹 Tests weight: 20 | SRP (Single-Responsibility Principle) - PHP files must act as libraries and never output text or perform any action when accessed directly in a browser
Almost there! Just fix the following items
  • 1× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/variations-select-menu-for-woocommerce/vsmw-variations-menu.php:12

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 93% from 29 tests

readme.txt Passed 16 tests

The readme.txt file is important because it is parsed by WordPress.org for the public listing of your plugin
2 plugin tags: woocomerce, variations

variations-select-menu-for-woocommerce/vsmw-variations-menu.php 85% from 13 tests

The primary PHP file in "Variations Select Menu For Woocommerce" version 1.1 is used by WordPress to initiate all plugin functionality
Please make the necessary changes and fix the following:
  • Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("variations-select-menu-for-woocommerce.php" instead of "vsmw-variations-menu.php")
  • Description: If Twitter did it, so should we! Keep the description under 140 characters (currently 181 characters long)

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of file extensions present in this plugin and a short test that no dangerous files are bundled with this plugin
Success! There were no dangerous files found in this plugin65 lines of code in 2 files:
LanguageFilesBlank linesComment linesLines of code
CSS18034
PHP1121931

PHP code Passed 2 tests

An overview of cyclomatic complexity and code structure
There were no cyclomatic complexity issued detected
Cyclomatic complexity
Average complexity per logical line of code0.07
Average class complexity0.00
▷ Minimum class complexity0.00
▷ Maximum class complexity0.00
Average method complexity0.00
▷ Minimum method complexity0.00
▷ Maximum method complexity0.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes0
▷ Abstract classes00.00%
▷ Concrete classes00.00%
▷ Final classes00.00%
Methods0
▷ Static methods00.00%
▷ Public methods00.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions4
▷ Named functions4100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
There are no PNG files in this plugin