Benchmarks
Plugin footprint 83% from 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | The install procedure must perform silently
This plugin's installer ran successfully
Server metrics [RAM: ▼0.01MB] [CPU: ▼7.71ms] Passed 4 tests
An overview of server-side resources used by WooCommerce - Payphone Gateway
No issues were detected with server-side resource usage
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.46 ▲0.00 | 36.40 ▼2.55 |
Dashboard /wp-admin | 3.31 ▼0.04 | 45.71 ▼15.49 |
Posts /wp-admin/edit.php | 3.36 ▲0.00 | 48.29 ▲1.90 |
Add New Post /wp-admin/post-new.php | 5.89 ▲0.00 | 81.61 ▼13.13 |
Media Library /wp-admin/upload.php | 3.23 ▲0.00 | 36.82 ▲0.32 |
Server storage [IO: ▲0.35MB] [DB: ▲0.00MB] Passed 3 tests
Analyzing filesystem and database footprints of this plugin
This plugin was installed successfully
Filesystem: 39 new files
Database: no new tables, 8 new options
New WordPress options |
---|
can_compress_scripts |
theysaidso_admin_options |
wc_gateway_payphone_bootstrap_warning_message |
widget_recent-posts |
widget_theysaidso_widget |
wc_payphone_version |
widget_recent-comments |
db_upgraded |
Browser metrics Passed 4 tests
Checking browser requirements for WooCommerce - Payphone Gateway
There were no issues detected in relation to browser resource usage
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,825 ▲79 | 13.34 ▼0.93 | 1.96 ▲0.30 | 44.30 ▲7.31 |
Dashboard /wp-admin | 2,209 ▲20 | 4.86 ▼0.12 | 97.05 ▼15.22 | 39.54 ▼9.29 |
Posts /wp-admin/edit.php | 2,086 ▼3 | 2.01 ▲0.03 | 40.22 ▲4.07 | 33.74 ▲0.72 |
Add New Post /wp-admin/post-new.php | 1,536 ▲17 | 23.23 ▲0.16 | 596.74 ▼74.90 | 51.52 ▼2.16 |
Media Library /wp-admin/upload.php | 1,391 ▲6 | 4.22 ▲0.03 | 96.07 ▼8.36 | 42.12 ▼2.11 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 75% from 4 tests
🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
You still need to fix the following
- Zombie WordPress options detected upon uninstall: 8 options
- wc_gateway_payphone_bootstrap_warning_message
- can_compress_scripts
- widget_recent-comments
- widget_theysaidso_widget
- widget_recent-posts
- theysaidso_admin_options
- db_upgraded
- wc_payphone_version
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
Good news, no errors were detected
SRP 50% from 2 tests
🔹 Tests weight: 20 | The single-responsibility principle applies for WordPress plugins as well - please make sure your PHP files perform no actions when accessed directly
Please take a closer look at the following
- 3× PHP files trigger server-side errors or warnings when accessed directly:
- > PHP Fatal error
Uncaught Error: Call to undefined function wc_gateway_payphone() in wp-content/plugins/wc-payphone-gateway/includes/wc-gateway-payphone-response.php:9
- > PHP Fatal error
Uncaught Error: Call to undefined function wc_gateway_payphone() in wp-content/plugins/wc-payphone-gateway/includes/wc-gateway-payphone.php:8
- > PHP Fatal error
Uncaught Error: Call to undefined function wc_gateway_payphone() in wp-content/plugins/wc-payphone-gateway/includes/wc-gateway-payphone-process.php:8
- > PHP Fatal error
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)
Everything seems fine, but this is not an exhaustive test
Optimizations
Plugin configuration 96% 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
2 plugin tags: woocommerce, gateway payment
wc-payphone-gateway/woocommerce-gateway-payphone.php 92% from 13 tests
Analyzing the main PHP file in "WooCommerce - Payphone Gateway" version 3.1.0
The following require your attention:
- Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("wc-payphone-gateway.php" instead of "woocommerce-gateway-payphone.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
Success! There were no dangerous files found in this plugin2,294 lines of code in 20 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PO File | 7 | 994 | 1,890 | 1,145 |
PHP | 11 | 256 | 404 | 1,085 |
CSS | 1 | 4 | 9 | 35 |
Markdown | 1 | 16 | 0 | 29 |
PHP code Passed 2 tests
A short review of cyclomatic complexity and code structure
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.27 |
Average class complexity | 15.11 |
▷ Minimum class complexity | 1.00 |
▷ Maximum class complexity | 45.00 |
Average method complexity | 2.84 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 19.00 |
Code structure | ||
---|---|---|
Namespaces | 0 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 9 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 9 | 100.00% |
▷ Final classes | 0 | 0.00% |
Methods | 69 | |
▷ Static methods | 0 | 0.00% |
▷ Public methods | 56 | 81.16% |
▷ Protected methods | 4 | 5.80% |
▷ Private methods | 9 | 13.04% |
Functions | 2 | |
▷ Named functions | 2 | 100.00% |
▷ Anonymous functions | 0 | 0.00% |
Constants | 6 | |
▷ Global constants | 4 | 66.67% |
▷ Class constants | 2 | 33.33% |
▷ Public constants | 2 | 100.00% |
Plugin size Passed 2 tests
Image compression Passed 2 tests
PNG files should be compressed to save space and minimize bandwidth usage
2 PNG files occupy 0.02MB with 0.01MB in potential savings
Potential savings
Compression of 2 random PNG files using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
assets/img/logo.png | 14.50KB | 4.15KB | ▼ 71.41% |
assets/img/logo-woocommerce.png | 3.05KB | 2.25KB | ▼ 26.16% |