89% filter-orders-by-status

Code Review | Filter orders by status

WordPress plugin Filter orders by status scored89%from 54 tests.

About plugin

  • Plugin page: filter-orders-by-...
  • Plugin version: 1.0
  • PHP compatiblity: 7.0+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.7-5.9
  • WordPress version: 6.3.1
  • First release: Jun 9, 2022
  • Latest release: Jun 9, 2022
  • Number of updates: 2
  • Update frequency: every 0.5 days
  • Top authors: marcomireles (100%)

Code review

54 tests

User reviews

1 review

Install metrics

30+ active /1,019 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
Installer ran successfully

Server metrics [RAM: ▲0.01MB] [CPU: ▼2.95ms] Passed 4 tests

Analyzing server-side resources used by Filter orders by status
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.48 ▲0.0140.14 ▼4.48
Dashboard /wp-admin3.32 ▲0.0249.54 ▼0.98
Posts /wp-admin/edit.php3.38 ▲0.0152.87 ▼4.04
Add New Post /wp-admin/post-new.php5.90 ▲0.0199.00 ▲5.38
Media Library /wp-admin/upload.php3.25 ▲0.0137.03 ▼2.29

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

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

Browser metrics Passed 4 tests

This is an overview of browser requirements for Filter orders by status
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,789 ▲2814.39 ▼0.021.69 ▼0.1337.67 ▼5.75
Dashboard /wp-admin2,192 ▲155.61 ▼0.0487.99 ▼14.2339.33 ▼5.08
Posts /wp-admin/edit.php2,097 ▼62.01 ▲0.0239.10 ▼2.7238.83 ▲1.97
Add New Post /wp-admin/post-new.php1,526 ▼823.42 ▲5.30670.84 ▲3.0362.94 ▼1.14
Media Library /wp-admin/upload.php1,400 ▲64.19 ▼0.04106.50 ▼5.3843.52 ▼1.15

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
It is recommended to fix the following
  • This plugin does not fully uninstall, leaving 6 options in the database
    • can_compress_scripts
    • widget_recent-posts
    • db_upgraded
    • widget_recent-comments
    • theysaidso_admin_options
    • widget_theysaidso_widget

Smoke tests Passed 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Even though no errors were found, this is by no means an exhaustive test

SRP Passed 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
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
No browser errors were detected

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 94% from 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
These attributes need your attention:
  • Plugin Name: "Plugin Name" should be replaced with the name of your plugin on the first line ( === filter-orders-by-status === )
Please take inspiration from this readme.txt

filter-orders-by-status/orders-by-status.php 85% from 13 tests

The main PHP script in "Filter orders by status" version 1.0 is automatically included on every request by WordPress
You should first fix the following items:
  • Text Domain: The text domain is optional since WordPress version 4.6; if you do specify it, it must be the same as the plugin slug
  • Main file name: It is recommended to name the main PHP file as the plugin slug ("filter-orders-by-status.php" instead of "orders-by-status.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | There should be no dangerous file extensions present in any WordPress plugin
No dangerous file extensions were detected69 lines of code in 3 files:
LanguageFilesBlank linesComment linesLines of code
PHP3152569

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
All good! No complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.55
Average class complexity1.00
▷ Minimum class complexity1.00
▷ Maximum class complexity1.00
Average method complexity1.00
▷ Minimum method complexity1.00
▷ Maximum method complexity1.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods5
▷ Static methods360.00%
▷ Public methods5100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions2
▷ Named functions2100.00%
▷ Anonymous functions00.00%
Constants3
▷ Global constants3100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

It is recommended to compress PNG files in your plugin to minimize bandwidth usage
1 PNG file occupies 0.05MB with 0.03MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
screenshot.png53.61KB19.57KB▼ 63.49%