84% product-filter-ajax-for-woo

Code Review | Product Filter AJAX for Woo

WordPress plugin Product Filter AJAX for Woo scored84%from 54 tests.

About plugin

  • Plugin page: product-filter-aj...
  • Plugin version: 1.0.0
  • PHP compatiblity: 5.0+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0-5.5
  • WordPress version: 6.3.1
  • First release: May 29, 2020
  • Latest release: Oct 7, 2020
  • Number of updates: 12
  • Update frequency: every 11.0 days
  • Top authors: mlfactory (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /445 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 successfully, without throwing any errors or notices

Server metrics [RAM: ▲0.10MB] [CPU: ▼4.26ms] Passed 4 tests

A check of server-side resources used by Product Filter AJAX for Woo
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.56 ▲0.1041.62 ▲0.34
Dashboard /wp-admin3.40 ▲0.1050.07 ▼0.94
Posts /wp-admin/edit.php3.45 ▲0.1050.78 ▲0.67
Add New Post /wp-admin/post-new.php5.98 ▲0.1085.91 ▼16.12
Media Library /wp-admin/upload.php3.32 ▲0.1036.38 ▼0.32

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

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

Browser metrics Passed 4 tests

Product Filter AJAX for Woo: an overview of browser usage
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,806 ▲3513.51 ▼0.791.60 ▼0.4942.92 ▼2.35
Dashboard /wp-admin2,209 ▲245.80 ▼0.0597.74 ▲0.2344.68 ▲3.52
Posts /wp-admin/edit.php2,095 ▲61.99 ▼0.0238.06 ▼2.1537.27 ▼1.10
Add New Post /wp-admin/post-new.php1,539 ▲2023.29 ▲0.21683.73 ▲12.0752.03 ▼0.16
Media Library /wp-admin/upload.php1,397 ▲94.25 ▼0.01103.50 ▼8.1346.19 ▼0.70

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
These items require your attention
  • This plugin does not fully uninstall, leaving 6 options in the database
    • can_compress_scripts
    • widget_recent-posts
    • widget_theysaidso_widget
    • widget_recent-comments
    • db_upgraded
    • theysaidso_admin_options

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Everything seems fine, however this is by no means an exhaustive test

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
The following issues need your attention
  • 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/product-filter-ajax-for-woo/product-filter-ajax-for-woo.php:38

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
Everything seems fine on the user side

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

The readme.txt file uses markdown syntax to describe your plugin to the world
4 plugin tags: ajax, woocommerce, filter, product filter

product-filter-ajax-for-woo/product-filter-ajax-for-woo.php Passed 13 tests

The main file in "Product Filter AJAX for Woo" v. 1.0.0 serves as a complement to information provided in readme.txt and as the entry point to the plugin
59 characters long description:
Simple / Modern Ajax Product Filter Plugin for WooCommerce.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | An overview of files in this plugin; executable files are not allowed
No dangerous file extensions were detected3,153 lines of code in 12 files:
LanguageFilesBlank linesComment linesLines of code
CSS6101681,865
PHP257737982
JavaScript31346178
PO File15053128

PHP code Passed 2 tests

A short review of cyclomatic complexity and code structure
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.42
Average class complexity65.00
▷ Minimum class complexity32.00
▷ Maximum class complexity98.00
Average method complexity11.67
▷ Minimum method complexity1.00
▷ Maximum method complexity66.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes2
▷ Abstract classes00.00%
▷ Concrete classes2100.00%
▷ Final classes00.00%
Methods13
▷ Static methods1184.62%
▷ Public methods13100.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
No PNG images were found in this plugin