Benchmarks
Plugin footprint 83% from 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | Checking the installer triggered no errors
The plugin installed successfully, without throwing any errors or notices
Server metrics [RAM: ▲0.02MB] [CPU: ▼8.66ms] Passed 4 tests
An overview of server-side resources used by ELEX WooCommerce Discount Per Payment Method
This plugin does not affect your website's performance
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.50 ▲0.03 | 34.12 ▼7.28 |
Dashboard /wp-admin | 3.34 ▼0.01 | 45.58 ▼15.14 |
Posts /wp-admin/edit.php | 3.39 ▲0.03 | 46.80 ▼0.56 |
Add New Post /wp-admin/post-new.php | 5.92 ▲0.03 | 91.49 ▼11.04 |
Media Library /wp-admin/upload.php | 3.26 ▲0.03 | 34.11 ▼1.18 |
Server storage [IO: ▲0.81MB] [DB: ▲0.00MB] Passed 3 tests
How much does this plugin use your filesystem and database?
This plugin installed successfully
Filesystem: 27 new files
Database: no new tables, 6 new options
New WordPress options |
---|
theysaidso_admin_options |
can_compress_scripts |
db_upgraded |
widget_recent-comments |
widget_recent-posts |
widget_theysaidso_widget |
Browser metrics Passed 4 tests
An overview of browser requirements for ELEX WooCommerce Discount Per Payment Method
Minimal impact on browser resources
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,810 ▲63 | 14.68 ▲0.33 | 1.56 ▼0.10 | 35.34 ▼7.66 |
Dashboard /wp-admin | 2,218 ▲41 | 5.68 ▲0.06 | 91.42 ▼9.50 | 40.56 ▼5.56 |
Posts /wp-admin/edit.php | 2,121 ▲18 | 2.02 ▲0.01 | 35.56 ▼2.94 | 34.88 ▲1.85 |
Add New Post /wp-admin/post-new.php | 1,541 ▲10 | 23.34 ▲0.43 | 586.70 ▼69.46 | 47.64 ▼18.73 |
Media Library /wp-admin/upload.php | 1,423 ▲23 | 4.28 ▲0.11 | 100.67 ▲3.99 | 41.32 ▼2.27 |
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
- This plugin does not fully uninstall, leaving 6 options in the database
- theysaidso_admin_options
- db_upgraded
- widget_theysaidso_widget
- widget_recent-posts
- can_compress_scripts
- widget_recent-comments
Smoke tests 50% 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)
Good news, no errors were detected
SRP 0% 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
The following issues need your attention
- 1× PHP files perform the action of outputting non-empty strings when accessed directly:
- > /wp-content/plugins/elex-discount-per-payment-method/review_and_troubleshoot_notify/resources/logo.php
- 4× GET requests to PHP files trigger server-side errors or Error 500 responses:
- > PHP Fatal error
Uncaught Error: Call to undefined function add_action() in wp-content/plugins/elex-discount-per-payment-method/includes/scripts.php:8
- > PHP Fatal error
Uncaught Error: Call to undefined function esc_attr() in wp-content/plugins/elex-discount-per-payment-method/review_and_troubleshoot_notify/resources/review.php:58
- > PHP Fatal error
Uncaught Error: Call to undefined function esc_html_e() in wp-content/plugins/elex-discount-per-payment-method/includes/market.php:108
- > PHP Fatal error
Uncaught Error: Call to undefined function esc_attr() in wp-content/plugins/elex-discount-per-payment-method/review_and_troubleshoot_notify/resources/troubleshoot.php:59
- > PHP Fatal error
User-side errors Passed 1 test
🔹 Test weight: 20 | This is a shallow check for browser errors
There were no browser issues found
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 your attention:
- Donate link: Please fix this invalid url: ""
elex-discount-per-payment-method/elex-discount-per-payment-method.php 92% from 13 tests
The primary PHP file in "ELEX WooCommerce Discount Per Payment Method" version 1.2.0 is used by WordPress to initiate all plugin functionality
You should first fix the following items:
- Requires at least: The required version number did not match the one declared in readme.txt ("3.0.1" instead of "2.6.0")
Code Analysis Passed 3 tests
File types Passed 1 test
🔸 Test weight: 35 | A short check of programming languages and file extensions; no executable files are allowed
No dangerous file extensions were detected8,315 lines of code in 16 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
CSS | 2 | 41 | 8 | 6,914 |
PHP | 10 | 176 | 53 | 932 |
PO File | 3 | 93 | 102 | 395 |
JavaScript | 1 | 52 | 2 | 74 |
PHP code Passed 2 tests
A brief analysis of cyclomatic complexity and code structure for this plugin
All good! No complexity issues found
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.30 |
Average class complexity | 18.50 |
▷ Minimum class complexity | 14.00 |
▷ Maximum class complexity | 23.00 |
Average method complexity | 3.06 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 10.00 |
Code structure | ||
---|---|---|
Namespaces | 0 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 2 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 2 | 100.00% |
▷ Final classes | 0 | 0.00% |
Methods | 17 | |
▷ Static methods | 0 | 0.00% |
▷ Public methods | 17 | 100.00% |
▷ Protected methods | 0 | 0.00% |
▷ Private methods | 0 | 0.00% |
Functions | 4 | |
▷ Named functions | 2 | 50.00% |
▷ Anonymous functions | 2 | 50.00% |
Constants | 0 | |
▷ Global constants | 0 | 0.00% |
▷ Class constants | 0 | 0.00% |
▷ Public constants | 0 | 0.00% |
Plugin size 50% from 2 tests
Image compression 50% from 2 tests
Often times overlooked, PNG files can occupy unnecessary space in your plugin
7 PNG files occupy 0.57MB with 0.44MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
assets/logo/Catalog Mode.png | 85.64KB | 21.17KB | ▼ 75.28% |
assets/logo/Name Your Price.png | 75.69KB | 17.13KB | ▼ 77.37% |
assets/logo/bulk_edit.png | 69.40KB | 15.94KB | ▼ 77.03% |
assets/logo/Hide WooCommerce.png | 79.45KB | 18.13KB | ▼ 77.19% |
assets/logo/dynamic_pricing.png | 90.78KB | 22.92KB | ▼ 74.75% |