Benchmarks
Plugin footprint 82% 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.20MB] [CPU: ▼1.96ms] 75% from 4 tests
Server-side resources used by DBargain
Please fix the following
- CPU: Total CPU usage should be kept under 500.00ms (currently 525.31ms on /wp-admin/admin.php?page=dbargain_settings)
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.66 ▲0.19 | 41.33 ▼0.69 |
Dashboard /wp-admin | 3.50 ▲0.19 | 46.34 ▼4.91 |
Posts /wp-admin/edit.php | 3.62 ▲0.25 | 49.18 ▲0.94 |
Add New Post /wp-admin/post-new.php | 6.10 ▲0.21 | 92.65 ▼3.16 |
Media Library /wp-admin/upload.php | 3.42 ▲0.19 | 37.22 ▲3.55 |
User Guide /wp-admin/admin.php?page=user_guide | 3.39 | 32.25 |
Session Chat History /wp-admin/admin.php?page=chat | 3.40 | 33.52 |
Settings /wp-admin/admin.php?page=dbargain_settings | 3.39 | 525.31 |
All Offers /wp-admin/admin.php?page=dbargain | 3.39 | 465.22 |
Server storage [IO: ▲0.10MB] [DB: ▲0.00MB] Passed 3 tests
Analyzing filesystem and database footprints of this plugin
There were no storage issued detected upon installing this plugin
Filesystem: 13 new files
Database: no new tables, 7 new options
New WordPress options |
---|
theysaidso_admin_options |
widget_theysaidso_widget |
widget_recent-comments |
widget_recent-posts |
can_compress_scripts |
recovery_mode_email_last_sent |
db_upgraded |
Browser metrics Passed 4 tests
This is an overview of browser requirements for DBargain
Normal browser usage
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,930 ▲183 | 13.56 ▼1.21 | 8.83 ▲7.11 | 39.19 ▼5.88 |
Dashboard /wp-admin | 2,254 ▲73 | 5.99 ▲0.31 | 98.53 ▼7.88 | 42.05 ▼3.00 |
Posts /wp-admin/edit.php | 2,161 ▲58 | 2.34 ▲0.37 | 43.78 ▲3.73 | 35.19 ▼4.36 |
Add New Post /wp-admin/post-new.php | 1,572 ▲43 | 23.66 ▲0.67 | 622.18 ▼41.43 | 33.02 ▼23.03 |
Media Library /wp-admin/upload.php | 1,453 ▲50 | 4.51 ▲0.30 | 100.24 ▲0.43 | 40.69 ▼3.60 |
User Guide /wp-admin/admin.php?page=user_guide | 866 | 2.08 | 31.09 | 26.58 |
Session Chat History /wp-admin/admin.php?page=chat | 719 | 1.51 | 6.73 | 19.74 |
Settings /wp-admin/admin.php?page=dbargain_settings | 863 | 2.09 | 26.90 | 24.66 |
All Offers /wp-admin/admin.php?page=dbargain | 863 | 2.10 | 26.51 | 24.24 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 75% from 4 tests
🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
The following items require your attention
- The uninstall procedure has failed, leaving 7 options in the database
- widget_theysaidso_widget
- recovery_mode_email_last_sent
- widget_recent-comments
- db_upgraded
- theysaidso_admin_options
- widget_recent-posts
- can_compress_scripts
Smoke tests 50% from 4 tests
Server-side errors 0% from 1 test
🔹 Test weight: 20 | A smoke test targeting server-side errors
Please fix the following server-side errors
- 3 occurences, only the last one shown
- > GET request to /wp-admin/admin.php?page=dbargain
- > Warning in wp-content/plugins/v-bargain/templates/expire.php+4
session_start(): Cannot start session when headers already sent
- > GET request to /wp-admin/admin.php?page=chat
- > Notice in wp-content/plugins/v-bargain/templates/chat.php+15
Undefined variable: sid
- > GET request to /wp-admin/admin.php?page=chat
- > Notice in wp-content/plugins/v-bargain/templates/chat.php+15
Undefined variable: pid
- > GET request to /wp-admin/admin.php?page=chat
- > Error in wp-content/plugins/v-bargain/templates/chat.php+25
Uncaught Error: Call to undefined function wc_get_product() in wp-content/plugins/v-bargain/templates/chat.php:25
Stack trace:
#0 wp-content/plugins/v-bargain/include/class-dbargain.php(667): require_once()
#1 wp-includes/class-wp-hook.php(310): DBargain::chat()
#2 wp-includes/class-wp-hook.php(334): WP_Hook->apply_filters()
#3 wp-includes/plugin.php(517): WP_Hook->do_action()
#4 wp-admin/admin.php(259): do_action()
#5 {main}
thrown
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 fix the following
- 1× 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/v-bargain/include/class-dbargain.php:168
- > PHP Fatal error
User-side errors Passed 1 test
🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
Everything seems fine on the user side
Optimizations
Plugin configuration 93% from 29 tests
readme.txt Passed 16 tests
Often overlooked, readme.txt is one of the most important files in your plugin
6 plugin tags: bargaining plugin wordpress, tool to boost sales, bargaining tool, d-bargain, bargain...
v-bargain/v-bargain.php 85% from 13 tests
The main PHP script in "DBargain" version 4.0.9 is automatically included on every request by WordPress
Please make the necessary changes and fix the following:
- Requires at least: The required version number did not match the one declared in readme.txt ("5.4" instead of "4.2.0")
- Text Domain: The text domain name should consist of only dashes and lowercase characters
Code Analysis Passed 3 tests
File types Passed 1 test
🔸 Test weight: 35 | A short glimpse at programming languages used with this plugin and a check that no dangerous files are present
Good job! No executable or dangerous file extensions detected1,940 lines of code in 11 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 9 | 360 | 221 | 1,789 |
JavaScript | 2 | 32 | 9 | 151 |
PHP code Passed 2 tests
Analyzing logical lines of code, cyclomatic complexity, and other code metrics
No complexity issues detected
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.34 |
Average class complexity | 55.00 |
▷ Minimum class complexity | 4.00 |
▷ Maximum class complexity | 106.00 |
Average method complexity | 4.27 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 36.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 | 33 | |
▷ Static methods | 25 | 75.76% |
▷ Public methods | 33 | 100.00% |
▷ Protected methods | 0 | 0.00% |
▷ Private methods | 0 | 0.00% |
Functions | 0 | |
▷ Named functions | 0 | 0.00% |
▷ Anonymous functions | 0 | 0.00% |
Constants | 1 | |
▷ Global constants | 1 | 100.00% |
▷ Class constants | 0 | 0.00% |
▷ Public constants | 0 | 0.00% |
Plugin size Passed 2 tests
Image compression Passed 2 tests
Using a strong compression for your PNG files is a great way to speed-up your plugin
1 PNG file occupies 0.02MB with 0.01MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
include/assets/cart_img.png | 16.25KB | 10.10KB | ▼ 37.87% |