Benchmarks
Plugin footprint 48% from 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
Install script ran successfully
Server metrics [RAM: ▼0.22MB] [CPU: ▼9.98ms] Passed 4 tests
An overview of server-side resources used by YoCommerce
Server-side resource usage in normal parameters
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.54 ▲0.08 | 44.24 ▼0.45 |
Dashboard /wp-admin | 3.42 ▲0.11 | 53.78 ▼2.57 |
Posts /wp-admin/edit.php | 3.54 ▲0.18 | 56.59 ▲0.41 |
Add New Post /wp-admin/post-new.php | 4.72 ▼1.18 | 53.41 ▼37.32 |
Media Library /wp-admin/upload.php | 3.35 ▲0.11 | 45.33 ▲8.98 |
Server storage [IO: ▲0.05MB] [DB: ▲0.00MB] Passed 3 tests
Analyzing filesystem and database footprints of this plugin
No storage issues were detected
Filesystem: 7 new files
Database: 4 new tables, 7 new options
New tables |
---|
wp_plugin_yocommerce_goods |
wp_plugin_yocommerce_orders |
wp_plugin_yocommerce_settings |
wp_plugin_yocommerce_settings_2 |
New WordPress options |
---|
widget_theysaidso_widget |
widget_recent-comments |
theysaidso_admin_options |
can_compress_scripts |
db_upgraded |
widget_wpb_widget |
widget_recent-posts |
Browser metrics Passed 4 tests
A check of browser resources used by YoCommerce
Minimal impact on browser resources
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,821 ▲10 | 14.45 ▼0.03 | 1.84 ▼0.22 | 43.05 ▼0.88 |
Dashboard /wp-admin | 2,212 ▲6 | 4.89 ▼0.97 | 110.71 ▼6.51 | 77.08 ▲34.28 |
Posts /wp-admin/edit.php | 2,116 ▲27 | 2.01 ▲0.00 | 38.33 ▲2.14 | 34.57 ▲0.51 |
Add New Post /wp-admin/post-new.php | 6,594 ▲5,080 | 26.93 ▲9.24 | 938.28 ▲252.18 | 60.93 ▼1.32 |
Media Library /wp-admin/upload.php | 1,405 ▲20 | 4.13 ▼0.04 | 100.82 ▲0.52 | 79.84 ▲35.39 |
Uninstaller [IO: ✅] [DB: ▲0.00MB] 25% from 4 tests
🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
These items require your attention
- This plugin cannot be uninstalled
- > Notice in wp-content/plugins/yocommerce/index.php+284
Undefined index: yocommerce_order_id
- The uninstall procedure failed, leaving 1 table in the database
- wp_plugin_yocommerce_settings_2
- This plugin does not fully uninstall, leaving 7 options in the database
- widget_recent-comments
- widget_theysaidso_widget
- theysaidso_admin_options
- widget_recent-posts
- db_upgraded
- can_compress_scripts
- widget_wpb_widget
Smoke tests 75% from 4 tests
Server-side errors Passed 1 test
🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
Even though no errors were found, this is by no means an exhaustive test
SRP 50% from 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
Please take a closer look at the following
- 4× PHP files trigger errors when accessed directly with GET requests:
- > PHP Fatal error
Uncaught Error: Class 'WP_Widget' not found in wp-content/plugins/yocommerce/yocommerce_widget.class.php:3
- > PHP Fatal error
Uncaught Error: Call to a member function get_results() on null in wp-content/plugins/yocommerce/yocommerce_paypalfunctions.php:11
- > PHP Fatal error
Uncaught Error: Class 'WP_Widget' not found in wp-content/plugins/yocommerce/yocommerce_widget.class.php:3
- > PHP Fatal error
Uncaught Error: Call to undefined function add_action() in wp-content/plugins/yocommerce/yocommerce_admin.php:20
- > PHP Fatal error
User-side errors Passed 1 test
🔹 Test weight: 20 | This is a shallow check for browser errors
No browser errors were detected
Optimizations
Plugin configuration 93% from 29 tests
readme.txt 94% from 16 tests
Often overlooked, readme.txt is one of the most important files in your plugin
These attributes need to be fixed:
- Plugin Name: You should set the name of your plugin on the first line (
=== yocommerce ===
)
yocommerce/index.php 92% from 13 tests
The main PHP script in "YoCommerce" version 1.3 is automatically included on every request by WordPress
The following require your attention:
- Main file name: Please rename the main PHP file in this plugin to the plugin slug ("yocommerce.php" instead of "index.php")
Code Analysis Passed 3 tests
File types Passed 1 test
🔸 Test weight: 35 | A short review of files and their extensions; it is not recommended to include executable files
Everything looks great! No dangerous files found in this plugin663 lines of code in 5 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 5 | 266 | 302 | 663 |
PHP code Passed 2 tests
A brief analysis of cyclomatic complexity and code structure for this plugin
No complexity issues detected
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.26 |
Average class complexity | 12.00 |
▷ Minimum class complexity | 12.00 |
▷ Maximum class complexity | 12.00 |
Average method complexity | 3.75 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 10.00 |
Code structure | ||
---|---|---|
Namespaces | 0 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 1 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 1 | 100.00% |
▷ Final classes | 0 | 0.00% |
Methods | 4 | |
▷ Static methods | 0 | 0.00% |
▷ Public methods | 4 | 100.00% |
▷ Protected methods | 0 | 0.00% |
▷ Private methods | 0 | 0.00% |
Functions | 24 | |
▷ Named functions | 24 | 100.00% |
▷ Anonymous functions | 0 | 0.00% |
Constants | 0 | |
▷ Global constants | 0 | 0.00% |
▷ Class constants | 0 | 0.00% |
▷ Public constants | 0 | 0.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.01MB with 0.01MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
buy.png | 11.19KB | 4.54KB | ▼ 59.40% |