90% wpc-show-single-variations

Code Review | WPC Show Single Variations for WooCommerce

WordPress plugin WPC Show Single Variations for WooCommerce scored90%from 54 tests.

About plugin

  • Plugin page: wpc-show-single-v...
  • Plugin version: 2.3.5
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0-6.4
  • WordPress version: 6.3.1
  • First release: Oct 11, 2019
  • Latest release: Nov 10, 2023
  • Number of updates: 48
  • Update frequency: every 31.1 days
  • Top authors: wpclever (100%)

Code review

54 tests

User reviews

10 reviews

Install metrics

1,000+ active /27,110 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
Installer ran successfully

Server metrics [RAM: ▲0.02MB] [CPU: ▼9.61ms] Passed 4 tests

An overview of server-side resources used by WPC Show Single Variations for WooCommerce
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.48 ▲0.0238.12 ▼0.62
Dashboard /wp-admin3.32 ▲0.0245.29 ▼1.99
Posts /wp-admin/edit.php3.37 ▲0.0247.79 ▼3.90
Add New Post /wp-admin/post-new.php5.90 ▲0.0293.20 ▼31.94
Media Library /wp-admin/upload.php3.24 ▲0.0233.48 ▲1.73

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

How much does this plugin use your filesystem and database?
The plugin installed successfully
Filesystem: 17 new files
Database: no new tables, 6 new options
New WordPress options
can_compress_scripts
widget_recent-posts
theysaidso_admin_options
widget_recent-comments
widget_theysaidso_widget
db_upgraded

Browser metrics Passed 4 tests

WPC Show Single Variations for WooCommerce: an overview of browser usage
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,790 ▲2814.37 ▲0.021.75 ▲0.1444.35 ▲1.04
Dashboard /wp-admin2,192 ▲255.49 ▼0.2591.83 ▼19.1837.24 ▼5.85
Posts /wp-admin/edit.php2,103 ▼01.96 ▼0.0540.70 ▼0.5835.75 ▲1.19
Add New Post /wp-admin/post-new.php1,526 ▼023.11 ▼0.17592.09 ▼103.3551.73 ▼7.11
Media Library /wp-admin/upload.php1,397 ▼34.21 ▲0.04101.58 ▲6.1642.25 ▲0.21

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
The following items require your attention
  • This plugin does not fully uninstall, leaving 6 options in the database
    • db_upgraded
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • widget_recent-posts
    • widget_recent-comments
    • can_compress_scripts

Smoke tests Passed 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Even though everything seems fine, this is not an exhaustive test

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
No output text or server-side errors detected on direct access of PHP files

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
No browser errors were detected

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
6 plugin tags: variation, wpc, single, woo, variable...

wpc-show-single-variations/wpc-show-single-variations.php Passed 13 tests

The main PHP script in "WPC Show Single Variations for WooCommerce" version 2.3.5 is automatically included on every request by WordPress
122 characters long description:
WPC Show Single Variations help you show all variations as single products on catalog pages (shop, category, tag, search).

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short glimpse at programming languages used with this plugin and a check that no dangerous files are present
Success! There were no dangerous files found in this plugin1,488 lines of code in 15 files:
LanguageFilesBlank linesComment linesLines of code
PHP813424902
CSS3887469
JavaScript311388
SVG10029

PHP code Passed 2 tests

Analyzing logical lines of code, cyclomatic complexity, and other code metrics
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.43
Average class complexity16.14
▷ Minimum class complexity1.00
▷ Maximum class complexity38.00
Average method complexity3.47
▷ Minimum method complexity1.00
▷ Maximum method complexity26.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes7
▷ Abstract classes00.00%
▷ Concrete classes7100.00%
▷ Final classes00.00%
Methods43
▷ Static methods511.63%
▷ Public methods3990.70%
▷ Protected methods00.00%
▷ Private methods49.30%
Functions1
▷ Named functions00.00%
▷ Anonymous functions1100.00%
Constants9
▷ Global constants9100.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
PNG images were not found in this plugin