78% filter-plus

Code Review | Advanced Filter Plugin for WooCommerce - Filter Plus

WordPress plugin Advanced Filter Plugin for WooCommerce - Filter Plus scored78%from 54 tests.

About plugin

  • Plugin page: filter-plus
  • Plugin version: 1.0.0
  • PHP compatiblity: 7.3+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.2-6.3.1
  • WordPress version: 6.3.1
  • First release: Oct 24, 2023
  • Latest release: Oct 24, 2023
  • Number of updates: 2
  • Update frequency: every 0.5 days
  • Top authors: markutos987 (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /11 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
This plugin's installer ran successfully

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

Server-side resources used by Advanced Filter Plugin for WooCommerce - Filter Plus
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.49 ▲0.0342.46 ▼8.58
Dashboard /wp-admin3.33 ▲0.0253.44 ▼10.06
Posts /wp-admin/edit.php3.44 ▲0.0856.63 ▲2.69
Add New Post /wp-admin/post-new.php5.91 ▲0.02117.92 ▲17.37
Media Library /wp-admin/upload.php3.25 ▲0.0239.07 ▲4.49
Filter Plus /wp-admin/admin.php?page=filter_plus3.2242.86

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

Input-output and database impact of this plugin
No storage issues were detected
Filesystem: 49 new files
Database: no new tables, 6 new options
New WordPress options
widget_theysaidso_widget
widget_recent-comments
can_compress_scripts
widget_recent-posts
db_upgraded
theysaidso_admin_options

Browser metrics Passed 4 tests

Checking browser requirements for Advanced Filter Plugin for WooCommerce - Filter Plus
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,031 ▲24514.03 ▼0.1314.07 ▲11.8645.64 ▼10.12
Dashboard /wp-admin2,294 ▲1175.58 ▼0.0385.88 ▼20.1338.99 ▼17.55
Posts /wp-admin/edit.php2,202 ▲1022.02 ▲0.0243.58 ▲2.5540.30 ▼1.09
Add New Post /wp-admin/post-new.php1,557 ▲3123.12 ▼0.34692.32 ▼21.1165.76 ▲11.26
Media Library /wp-admin/upload.php1,495 ▲924.14 ▼0.09117.33 ▲18.0649.72 ▲7.08
Filter Plus /wp-admin/admin.php?page=filter_plus1,0652.1830.3142.00

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
It is recommended to fix the following
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • db_upgraded
    • widget_recent-posts
    • can_compress_scripts
    • widget_theysaidso_widget
    • widget_recent-comments
    • theysaidso_admin_options

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Everything seems fine, however this is by no means an exhaustive test

SRP 0% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle applies for WordPress plugins as well - please make sure your PHP files perform no actions when accessed directly
Please fix the following items
  • 5× PHP files output text when accessed directly:
    • > /wp-content/plugins/filter-plus/templates/search-filter/template-1/left-side/filter-layout-attr-grid.php
    • > /wp-content/plugins/filter-plus/templates/search-filter/template-2/left-side/filter-param.php
    • > /wp-content/plugins/filter-plus/templates/search-filter/template-2/left-side/categories.php
    • > /wp-content/plugins/filter-plus/templates/search-filter/template-1/left-side/filter-param.php
    • > /wp-content/plugins/filter-plus/templates/search-filter/template-1/right-side/sort-bar.php
  • 5× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Trait 'FilterPlus\\Utils\\Singleton' not found in wp-content/plugins/filter-plus/core/core.php on line 12
    • > PHP Fatal error
      Trait 'FilterPlus\\Utils\\Singleton' not found in wp-content/plugins/filter-plus/core/frontend/search-filter/actions.php on line 12
    • > PHP Fatal error
      Trait 'FilterPlus\\Utils\\Singleton' not found in wp-content/plugins/filter-plus/core/frontend/shortcodes.php on line 12
    • > PHP Fatal error
      Trait 'FilterPlus\\Utils\\Singleton' not found in wp-content/plugins/filter-plus/core/admin/menus.php on line 15
    • > PHP Fatal error
      Uncaught Error: Class 'FilterPlus' not found in wp-content/plugins/filter-plus/core/admin/views/shortcodes.php:2

User-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
Everything seems fine on the user side

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file uses markdown syntax to describe your plugin to the world
Please fix the following attributes:
  • Screenshots: Add images for these screenshots: #1 (screenshot-1), #2 (screenshot-2)
You can look at the official readme.txt

filter-plus/filter-plus.php 85% from 13 tests

The principal PHP file in "Advanced Filter Plugin for WooCommerce - Filter Plus" v. 1.0.0 is loaded by WordPress automatically on each request
Please make the necessary changes and fix the following:
  • Requires at least: Required version must match the one declared in readme.txt ("4.7" instead of "5.2")
  • Requires PHP: Required version must match the one declared in readme.txt ("7.0" instead of "7.3")

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
Success! There were no dangerous files found in this plugin4,870 lines of code in 44 files:
LanguageFilesBlank linesComment linesLines of code
CSS5100211,760
PHP303144661,633
JavaScript459119754
Sass21282716
SVG2006
Markdown1001

PHP code Passed 2 tests

This plugin's cyclomatic complexity and code structure detailed below
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.41
Average class complexity12.70
▷ Minimum class complexity1.00
▷ Maximum class complexity67.00
Average method complexity2.86
▷ Minimum method complexity1.00
▷ Maximum method complexity16.00
Code structure
Namespaces7
Interfaces0
Traits1
Classes9
▷ Abstract classes00.00%
▷ Concrete classes9100.00%
▷ Final classes111.11%
Methods63
▷ Static methods3860.32%
▷ Public methods6196.83%
▷ Protected methods00.00%
▷ Private methods23.17%
Functions2
▷ Named functions2100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.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
There were not PNG files found in your plugin