90% widget-display-filter

Code Review | Widget Display Filter

WordPress plugin Widget Display Filter scored90%from 54 tests.

About plugin

  • Plugin page: widget-display-fi...
  • Plugin version: 2.0.0
  • PHP compatiblity: 7.3+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.9-5.9
  • WordPress version: 6.3.1
  • First release: Aug 7, 2015
  • Latest release: Feb 24, 2022
  • Number of updates: 9
  • Update frequency: every 266.0 days
  • Top authors: enomoto celtislab (100%)

Code review

54 tests

User reviews

2 reviews

Install metrics

60+ active /2,990 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
This plugin's installer ran successfully

Server metrics [RAM: ▲0.13MB] [CPU: ▼6.59ms] Passed 4 tests

This is a short check of server-side resources used by Widget Display Filter
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.50 ▲0.0433.93 ▼4.51
Dashboard /wp-admin3.48 ▲0.1447.92 ▼7.78
Posts /wp-admin/edit.php3.59 ▲0.2446.12 ▼5.45
Add New Post /wp-admin/post-new.php6.06 ▲0.1882.41 ▼8.62
Media Library /wp-admin/upload.php3.40 ▲0.1836.92 ▲5.46
Widget Display Filter /wp-admin/themes.php?page=widget_display_filter_manage_page3.3938.29

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

A short overview of filesystem and database impact
This plugin was installed successfully
Filesystem: 8 new files
Database: no new tables, 6 new options
New WordPress options
db_upgraded
can_compress_scripts
theysaidso_admin_options
widget_recent-comments
widget_theysaidso_widget
widget_recent-posts

Browser metrics Passed 4 tests

Widget Display Filter: an overview of browser usage
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,829 ▲9413.23 ▼1.151.67 ▼0.4737.74 ▼13.09
Dashboard /wp-admin2,210 ▲224.84 ▼0.04101.71 ▼3.4540.24 ▲1.05
Posts /wp-admin/edit.php2,093 ▲12.02 ▼0.0139.11 ▼2.6735.54 ▼0.81
Add New Post /wp-admin/post-new.php1,538 ▼423.43 ▲5.05689.81 ▲55.7949.01 ▼2.73
Media Library /wp-admin/upload.php1,392 ▲14.19 ▼0.00104.09 ▲5.1744.25 ▲2.34
Widget Display Filter /wp-admin/themes.php?page=widget_display_filter_manage_page1,3962.3746.8947.38

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
These items require your attention
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • widget_recent-posts
    • theysaidso_admin_options
    • db_upgraded
    • can_compress_scripts
    • widget_recent-comments
    • widget_theysaidso_widget

Smoke tests Passed 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
The smoke test was a success, however most plugin functionality was not tested

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

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)
There were no browser issues found

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
5 plugin tags: filter, conditional tags, widget, hide, widget group block

widget-display-filter/widget-display-filter.php 92% from 13 tests

The entry point to "Widget Display Filter" version 2.0.0 is a PHP file that has certain tags in its header comment area
You should first fix the following items:
  • Text Domain: Since WordPress version 4.6 the text domain is optional; if specified, it must be the same as the plugin slug

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of file extensions present in this plugin and a short test that no dangerous files are bundled with this plugin
No dangerous file extensions were detected1,256 lines of code in 5 files:
LanguageFilesBlank linesComment linesLines of code
PHP23848851
JavaScript166180
PO File15157141
CSS111184

PHP code Passed 2 tests

This is a short overview of cyclomatic complexity and code structure for this plugin
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.57
Average class complexity106.50
▷ Minimum class complexity96.00
▷ Maximum class complexity117.00
Average method complexity11.05
▷ Minimum method complexity1.00
▷ Maximum method complexity80.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes2
▷ Abstract classes00.00%
▷ Concrete classes2100.00%
▷ Final classes00.00%
Methods21
▷ Static methods628.57%
▷ Public methods21100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions2
▷ Named functions150.00%
▷ Anonymous functions150.00%
Constants0
▷ Global constants00.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