90% wpc-smart-price-filter

Code Review | WPC Smart Price Filter for WooCommerce

WordPress plugin WPC Smart Price Filter for WooCommerce scored90%from 54 tests.

About plugin

  • Plugin page: wpc-smart-price-f...
  • Plugin version: 1.3.1
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0-6.3
  • WordPress version: 6.3.1
  • First release: Feb 26, 2019
  • Latest release: Sep 3, 2023
  • Number of updates: 32
  • Update frequency: every 51.7 days
  • Top authors: wpclever (100%)

Code review

54 tests

User reviews

2 reviews

Install metrics

600+ active /8,219 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.16MB] [CPU: ▼7.81ms] Passed 4 tests

Server-side resources used by WPC Smart Price Filter for WooCommerce
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.63 ▲0.1736.32 ▲0.19
Dashboard /wp-admin3.47 ▲0.1343.36 ▼16.28
Posts /wp-admin/edit.php3.59 ▲0.2347.17 ▲3.91
Add New Post /wp-admin/post-new.php6.07 ▲0.1979.25 ▼17.92
Media Library /wp-admin/upload.php3.40 ▲0.1734.33 ▲2.77
Essential Kit /wp-admin/admin.php?page=wpclever-kit3.3630.56
About /wp-admin/admin.php?page=wpclever3.3629.35

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

Input-output and database impact of this plugin
This plugin installed successfully
Filesystem: 13 new files
Database: no new tables, 6 new options
New WordPress options
can_compress_scripts
widget_theysaidso_widget
widget_recent-posts
db_upgraded
theysaidso_admin_options
widget_recent-comments

Browser metrics Passed 4 tests

A check of browser resources used by WPC Smart Price Filter for WooCommerce
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,875 ▲10413.23 ▼1.151.58 ▼0.4440.05 ▼0.99
Dashboard /wp-admin2,281 ▲965.85 ▲0.98102.45 ▲1.8786.12 ▲45.03
Posts /wp-admin/edit.php2,167 ▲782.05 ▲0.0636.90 ▲1.6535.90 ▲2.10
Add New Post /wp-admin/post-new.php1,596 ▲5423.31 ▲0.45666.75 ▲29.8347.78 ▼4.66
Media Library /wp-admin/upload.php1,463 ▲754.26 ▲0.08100.14 ▲5.6581.85 ▲40.38
Essential Kit /wp-admin/admin.php?page=wpclever-kit5,7302.2741.2852.87
About /wp-admin/admin.php?page=wpclever1,3862.1229.5834.30

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
It is recommended to fix the following
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • widget_theysaidso_widget
    • widget_recent-posts
    • db_upgraded
    • can_compress_scripts
    • theysaidso_admin_options
    • widget_recent-comments

Smoke tests Passed 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Even though no errors were found, this is by no means an exhaustive test

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

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
There were no browser issues found

Optimizations

Plugin configuration 97% from 29 tests

readme.txt 94% from 16 tests

Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
Attributes that need to be fixed: You can take inspiration from this readme.txt

wpc-smart-price-filter/wpc-smart-price-filter.php Passed 13 tests

"WPC Smart Price Filter for WooCommerce" version 1.3.1's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
110 characters long description:
WPC Smart Price Filter is an advanced widget help you to filter products by price with unlimited price ranges.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of programming languages used in this plugin; dangerous file extensions are not allowed
No dangerous file extensions were detected1,420 lines of code in 11 files:
LanguageFilesBlank linesComment linesLines of code
PHP413541853
CSS3836441
JavaScript311297
SVG10029

PHP code Passed 2 tests

A short review of cyclomatic complexity and code structure
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.55
Average class complexity29.20
▷ Minimum class complexity1.00
▷ Maximum class complexity88.00
Average method complexity5.52
▷ Minimum method complexity1.00
▷ Maximum method complexity40.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes5
▷ Abstract classes00.00%
▷ Concrete classes5100.00%
▷ Final classes00.00%
Methods32
▷ Static methods13.12%
▷ Public methods3093.75%
▷ Protected methods26.25%
▷ Private methods00.00%
Functions3
▷ Named functions266.67%
▷ Anonymous functions133.33%
Constants7
▷ Global constants7100.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
PNG images were not found in this plugin