Benchmarks
Plugin footprint 58% from 16 tests
Installer 0% from 1 test
🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
These installer errors require your attention
- This plugin did not install gracefully
- > User error in wp-content/plugins/codecorun-coupon-discount-rules/codecorun-cdr-plugin.php+34
Woocommerce plugin is missing
Server metrics [RAM: ▼0.16MB] [CPU: ▼17.59ms] Passed 4 tests
Analyzing server-side resources used by Codecorun - Coupon Discount Rules
This plugin does not affect your website's performance
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.02 ▼0.44 | 19.57 ▼24.74 |
Dashboard /wp-admin | 3.31 ▲0.01 | 33.06 ▼15.86 |
Posts /wp-admin/edit.php | 3.39 ▲0.03 | 34.58 ▼10.47 |
Add New Post /wp-admin/post-new.php | 5.62 ▼0.26 | 74.58 ▼19.27 |
Media Library /wp-admin/upload.php | 3.33 ▲0.10 | 31.88 ▼4.65 |
Discount Rules Notification /wp-admin/admin.php?page=codecorun-wcdr | 3.24 | 27.98 |
Server storage [IO: ▲0.54MB] [DB: ▲0.00MB] Passed 3 tests
How much does this plugin use your filesystem and database?
No storage issues were detected
Filesystem: 23 new files
Database: no new tables, 6 new options
New WordPress options |
---|
widget_recent-posts |
can_compress_scripts |
widget_recent-comments |
db_upgraded |
theysaidso_admin_options |
widget_theysaidso_widget |
Browser metrics Passed 4 tests
Checking browser requirements for Codecorun - Coupon Discount Rules
There were no issues detected in relation to browser resource usage
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,463 ▼294 | 13.26 ▼0.69 | 0.67 ▼1.23 | 19.56 ▼23.68 |
Dashboard /wp-admin | 2,213 ▲34 | 4.87 ▼0.02 | 100.03 ▼0.80 | 36.78 ▼4.74 |
Posts /wp-admin/edit.php | 2,096 ▲28 | 2.04 ▲0.03 | 37.39 ▲0.61 | 29.60 ▼2.49 |
Add New Post /wp-admin/post-new.php | 1,521 ▲1 | 22.98 ▲0.01 | 590.92 ▼27.91 | 89.93 ▲33.08 |
Media Library /wp-admin/upload.php | 1,398 ▲10 | 4.27 ▲0.07 | 97.09 ▼4.87 | 42.54 ▼1.87 |
Discount Rules Notification /wp-admin/admin.php?page=codecorun-wcdr | 1,764 | 7.22 | 156.39 | 105.74 |
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
Please fix the following items
- This plugin does not fully uninstall, leaving 6 options in the database
- theysaidso_admin_options
- db_upgraded
- can_compress_scripts
- widget_recent-comments
- widget_recent-posts
- widget_theysaidso_widget
Smoke tests 25% from 4 tests
Server-side errors 0% from 1 test
🔹 Test weight: 20 | This is a shallow check for server-side errors
These errors were triggered by the plugin
- > GET request to /wp-admin/admin.php?page=codecorun-wcdr
- > User notice in wp-includes/functions.php+5905
Function WP_Scripts::localize was called incorrectly. The $l10n parameter must be an array. To pass arbitrary data to scripts, use the wp_add_inline_script() function instead. Please see Debugging in WordPress for more information. (This message was added in version 5.7.0.)
SRP 0% from 2 tests
🔹 Tests weight: 20 | A shallow check of the single-responsibility principle; PHP files should perform no action - including output of placeholder text - and trigger no errors when accessed directly
Please fix the following
- 4× GET requests to PHP files return non-empty strings:
- > /wp-content/plugins/codecorun-coupon-discount-rules/codecorun-cdr-plugin.php
- > /wp-content/plugins/codecorun-coupon-discount-rules/admin/includes/codecorun-cdr-admin-class.php
- > /wp-content/plugins/codecorun-coupon-discount-rules/includes/codecorun-cdr-main-class.php
- > /wp-content/plugins/codecorun-coupon-discount-rules/includes/codecorun-cdr-common-class.php
- 14× PHP files trigger server errors when accessed directly (only 10 are shown):
- > PHP Notice
Undefined variable: params in wp-content/plugins/codecorun-coupon-discount-rules/templates/notification.php on line 2
- > PHP Notice
Trying to access array offset on value of type null in wp-content/plugins/codecorun-coupon-discount-rules/templates/notification.php on line 2
- > PHP Fatal error
Uncaught Error: Call to undefined function esc_url() in wp-content/plugins/codecorun-coupon-discount-rules/admin/templates/panel-marketing.php:10
- > PHP Notice
Trying to access array offset on value of type null in wp-content/plugins/codecorun-coupon-discount-rules/templates/notification.php on line 2
- > PHP Warning
Use of undefined constant CODECORUN_CDR_URL - assumed 'CODECORUN_CDR_URL' (this will throw an Error in a future version of PHP) in wp-content/plugins/codecorun-coupon-discount-rules/admin/templates/panel-marketing.php on line 7
- > PHP Notice
Trying to access array offset on value of type null in wp-content/plugins/codecorun-coupon-discount-rules/templates/notification.php on line 2
- > PHP Notice
Undefined variable: params in wp-content/plugins/codecorun-coupon-discount-rules/templates/notification.php on line 2
- > PHP Notice
Trying to access array offset on value of type null in wp-content/plugins/codecorun-coupon-discount-rules/templates/notification.php on line 2
- > PHP Notice
Undefined variable: params in wp-content/plugins/codecorun-coupon-discount-rules/templates/notification.php on line 2
- > PHP Notice
Trying to access array offset on value of type null in wp-content/plugins/codecorun-coupon-discount-rules/templates/notification.php on line 2
- > PHP Notice
User-side errors Passed 1 test
🔹 Test weight: 20 | This is a shallow check for browser errors
No browser issues were found
Optimizations
Plugin configuration 96% from 29 tests
readme.txt Passed 16 tests
It's important to format your readme.txt file correctly as it is parsed for the public listing of your plugin
5 plugin tags: rules, discounts, auto discounts, coupon, discount rules
codecorun-coupon-discount-rules/codecorun-cdr-plugin.php 92% from 13 tests
This is the main PHP file of "Codecorun - Coupon Discount Rules" version 1.3.1, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
The following require your attention:
- Main file name: Please rename the main PHP file in this plugin to the plugin slug ("codecorun-coupon-discount-rules.php" instead of "codecorun-cdr-plugin.php")
Code Analysis Passed 3 tests
File types Passed 1 test
🔸 Test weight: 35 | This is an overview of file extensions present in this plugin and a short test that no dangerous files are bundled with this plugin
No dangerous file extensions were detected10,779 lines of code in 17 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
JavaScript | 4 | 1,097 | 1,047 | 8,939 |
PHP | 7 | 195 | 336 | 993 |
CSS | 3 | 89 | 23 | 580 |
PO File | 1 | 82 | 88 | 197 |
SVG | 1 | 0 | 1 | 69 |
Markdown | 1 | 1 | 0 | 1 |
PHP code Passed 2 tests
A brief analysis of cyclomatic complexity and code structure for this plugin
There were no cyclomatic complexity issued detected
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.46 |
Average class complexity | 49.33 |
▷ Minimum class complexity | 6.00 |
▷ Maximum class complexity | 113.00 |
Average method complexity | 5.70 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 31.00 |
Code structure | ||
---|---|---|
Namespaces | 3 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 3 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 3 | 100.00% |
▷ Final classes | 0 | 0.00% |
Methods | 31 | |
▷ Static methods | 3 | 9.68% |
▷ Public methods | 31 | 100.00% |
▷ Protected methods | 0 | 0.00% |
▷ Private methods | 0 | 0.00% |
Functions | 6 | |
▷ Named functions | 3 | 50.00% |
▷ Anonymous functions | 3 | 50.00% |
Constants | 5 | |
▷ Global constants | 5 | 100.00% |
▷ Class constants | 0 | 0.00% |
▷ Public constants | 0 | 0.00% |
Plugin size Passed 2 tests
Image compression Passed 2 tests
Often times overlooked, PNG files can occupy unnecessary space in your plugin
1 PNG file occupies 0.02MB with 0.02MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
admin/assets/codecorun.png | 18.50KB | 0.67KB | ▼ 96.40% |