90% woof-by-category

Code Review | WOOF by Category

WordPress plugin WOOF by Category scored90%from 54 tests.

About plugin

  • Plugin page: woof-by-category
  • Plugin version: 3.0.1
  • PHP compatiblity: 7.0+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.4-6.3
  • WordPress version: 6.3.1
  • First release: Aug 24, 2017
  • Latest release: Aug 3, 2023
  • Number of updates: 93
  • Update frequency: every 23.3 days
  • Top authors: kaggdesign (100%)

Code review

54 tests

User reviews

19 reviews

Install metrics

2,000+ active /66,884 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▲0.00MB] [CPU: ▼6.28ms] Passed 4 tests

An overview of server-side resources used by WOOF by Category
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.46 ▲0.0039.33 ▼5.52
Dashboard /wp-admin3.31 ▲0.0052.29 ▲2.32
Posts /wp-admin/edit.php3.36 ▲0.0047.68 ▲0.21
Add New Post /wp-admin/post-new.php5.89 ▲0.0089.33 ▼18.46
Media Library /wp-admin/upload.php3.23 ▲0.0034.22 ▼1.33

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

Analyzing filesystem and database footprints of this plugin
This plugin installed successfully
Filesystem: 19 new files
Database: no new tables, 6 new options
New WordPress options
widget_theysaidso_widget
db_upgraded
can_compress_scripts
theysaidso_admin_options
widget_recent-comments
widget_recent-posts

Browser metrics Passed 4 tests

Checking browser requirements for WOOF by Category
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,800 ▲5414.74 ▲0.341.77 ▼0.1043.28 ▲1.09
Dashboard /wp-admin2,209 ▲214.86 ▼1.00111.23 ▲9.2742.92 ▲0.23
Posts /wp-admin/edit.php2,089 ▼02.06 ▲0.0534.89 ▼6.7033.37 ▼4.05
Add New Post /wp-admin/post-new.php1,533 ▲1423.38 ▲0.35640.22 ▼9.8153.05 ▼18.39
Media Library /wp-admin/upload.php1,382 ▼64.21 ▲0.08100.39 ▼6.8244.26 ▼4.59

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
These items require your attention
  • The uninstall procedure has failed, leaving 6 options in the database
    • widget_recent-posts
    • can_compress_scripts
    • widget_theysaidso_widget
    • db_upgraded
    • widget_recent-comments
    • theysaidso_admin_options

Smoke tests Passed 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check 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 just a short smoke test looking for browser issues
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

The readme.txt file is an important file in your plugin as it is parsed by WordPress.org to prepare the public listing of your plugin
4 plugin tags: filter category, filter, woocommerce products filter, woocommerce

woof-by-category/woof-by-category.php Passed 13 tests

The main PHP script in "WOOF by Category" version 3.0.1 is automatically included on every request by WordPress
113 characters long description:
WooCommerce Product Filter (WOOF) extension to display set of filters depending on current product category page.

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
Everything looks great! No dangerous files found in this plugin1,518 lines of code in 14 files:
LanguageFilesBlank linesComment linesLines of code
PHP113397911,410
PO File1161754
CSS112049
JSON1005

PHP code Passed 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.49
Average class complexity47.60
▷ Minimum class complexity1.00
▷ Maximum class complexity145.00
Average method complexity3.67
▷ Minimum method complexity1.00
▷ Maximum method complexity18.00
Code structure
Namespaces3
Interfaces0
Traits0
Classes5
▷ Abstract classes00.00%
▷ Concrete classes5100.00%
▷ Final classes00.00%
Methods89
▷ Static methods1921.35%
▷ Public methods5966.29%
▷ Protected methods1112.36%
▷ Private methods1921.35%
Functions3
▷ Named functions133.33%
▷ Anonymous functions266.67%
Constants8
▷ Global constants112.50%
▷ Class constants787.50%
▷ Public constants7100.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