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.01MB] [CPU: ▼1.93ms] Passed 4 tests
A check of server-side resources used by Discontinued Products
No issues were detected with server-side resource usage
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.47 ▲0.01 | 38.80 ▼5.98 |
Dashboard /wp-admin | 3.31 ▲0.01 | 50.55 ▲0.72 |
Posts /wp-admin/edit.php | 3.36 ▲0.01 | 54.44 ▲3.50 |
Add New Post /wp-admin/post-new.php | 5.89 ▲0.01 | 95.22 ▼5.97 |
Media Library /wp-admin/upload.php | 3.23 ▲0.01 | 40.93 ▲4.91 |
Server storage [IO: ▲0.04MB] [DB: ▲0.00MB] Passed 3 tests
Analyzing filesystem and database footprints of this plugin
The plugin installed successfully
Filesystem: 9 new files
Database: no new tables, 6 new options
New WordPress options |
---|
widget_recent-comments |
can_compress_scripts |
widget_recent-posts |
theysaidso_admin_options |
db_upgraded |
widget_theysaidso_widget |
Browser metrics Passed 4 tests
Checking browser requirements for Discontinued Products
There were no issues detected in relation to browser resource usage
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,800 ▲54 | 13.18 ▼1.38 | 5.29 ▲3.00 | 43.65 ▼4.24 |
Dashboard /wp-admin | 2,209 ▲21 | 4.89 ▼0.00 | 113.40 ▲12.79 | 43.26 ▲1.88 |
Posts /wp-admin/edit.php | 2,089 ▼3 | 2.02 ▲0.04 | 41.61 ▼1.19 | 34.87 ▼4.33 |
Add New Post /wp-admin/post-new.php | 1,514 ▼19 | 17.51 ▼5.65 | 647.12 ▼5.41 | 65.61 ▲12.99 |
Media Library /wp-admin/upload.php | 1,388 ▼3 | 4.18 ▼0.04 | 100.11 ▼6.03 | 42.97 ▼4.50 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 75% from 4 tests
🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
You still need to fix the following
- Zombie WordPress options detected upon uninstall: 6 options
- db_upgraded
- theysaidso_admin_options
- widget_theysaidso_widget
- widget_recent-posts
- widget_recent-comments
- can_compress_scripts
Smoke tests 75% from 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 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
Please take a closer look at the following
- 4× PHP files trigger errors when accessed directly with GET requests:
- > PHP Fatal error
Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/discontinued-products/woocommerce-template.php:108
- > PHP Fatal error
Uncaught Error: Call to undefined function apply_filters() in wp-content/plugins/discontinued-products/woocommerce-discontinued-products.php:21
- > PHP Fatal error
Uncaught Error: Call to undefined function add_action() in wp-content/plugins/discontinued-products/includes/wc-class-dp-discontinued-product.php:51
- > PHP Fatal error
Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/discontinued-products/includes/wc-class-dp-settings.php:24
- > PHP Fatal error
User-side errors Passed 1 test
🔹 Test weight: 20 | A shallow check that no browser errors were triggered
There were no browser issues found
Optimizations
Plugin configuration 93% from 29 tests
readme.txt Passed 16 tests
The readme.txt file is undoubtedly the most important file in your plugin, preparing it for public listing on WordPress.org
5 plugin tags: woocommerce products, woocommerce, discontinued, ecommerce, discontinued products
discontinued-products/woocommerce-discontinued-products.php 85% from 13 tests
"Discontinued Products" version 1.1.5's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
It is important to fix the following:
- 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: The principal plugin file should be the same as the plugin slug ("discontinued-products.php" instead of "woocommerce-discontinued-products.php")
Code Analysis Passed 3 tests
File types Passed 1 test
🔸 Test weight: 35 | This is a short overview of programming languages used in this plugin, detecting executable files
Good job! No executable or dangerous file extensions detected509 lines of code in 7 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 6 | 111 | 331 | 505 |
CSS | 1 | 0 | 0 | 4 |
PHP code Passed 2 tests
This is a very shot review of cyclomatic complexity and code structure
All good! No complexity issues found
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.26 |
Average class complexity | 6.40 |
▷ Minimum class complexity | 1.00 |
▷ Maximum class complexity | 19.00 |
Average method complexity | 1.90 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 9.00 |
Code structure | ||
---|---|---|
Namespaces | 0 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 5 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 5 | 100.00% |
▷ Final classes | 0 | 0.00% |
Methods | 30 | |
▷ Static methods | 2 | 6.67% |
▷ Public methods | 29 | 96.67% |
▷ Protected methods | 1 | 3.33% |
▷ Private methods | 0 | 0.00% |
Functions | 8 | |
▷ Named functions | 8 | 100.00% |
▷ Anonymous functions | 0 | 0.00% |
Constants | 2 | |
▷ Global constants | 2 | 100.00% |
▷ Class constants | 0 | 0.00% |
▷ Public constants | 0 | 0.00% |
Plugin size Passed 2 tests
Image compression Passed 2 tests
All PNG images should be compressed to minimize bandwidth usage for end users
There are no PNG files in this plugin