Benchmarks
Plugin footprint 83% from 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | The install procedure must perform silently
Install script ran successfully
Server metrics [RAM: ▲0.01MB] [CPU: ▼6.01ms] Passed 4 tests
Analyzing server-side resources used by Simple AdBlock Detector
No issues were detected with server-side resource usage
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.47 ▲0.01 | 45.80 ▲5.68 |
Dashboard /wp-admin | 3.31 ▲0.01 | 47.77 ▼14.17 |
Posts /wp-admin/edit.php | 3.36 ▲0.01 | 48.80 ▼0.67 |
Add New Post /wp-admin/post-new.php | 5.89 ▲0.01 | 86.59 ▼6.52 |
Media Library /wp-admin/upload.php | 3.24 ▲0.01 | 36.29 ▼2.68 |
Server storage [IO: ▲0.62MB] [DB: ▲0.00MB] Passed 3 tests
Input-output and database impact of this plugin
This plugin installed successfully
Filesystem: 16 new files
Database: no new tables, 10 new options
New WordPress options |
---|
sad_post_animation |
can_compress_scripts |
widget_recent-posts |
db_upgraded |
theysaidso_admin_options |
sad_post_devtools |
widget_recent-comments |
sad_post_title |
widget_theysaidso_widget |
sad_post_description |
Browser metrics Passed 4 tests
A check of browser resources used by Simple AdBlock Detector
Normal browser usage
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,840 ▲79 | 14.62 ▲0.46 | 2.34 ▲0.47 | 40.75 ▲0.24 |
Dashboard /wp-admin | 2,210 ▲30 | 5.61 ▼0.06 | 91.98 ▲2.25 | 81.33 ▲40.28 |
Posts /wp-admin/edit.php | 2,121 ▲21 | 1.97 ▼0.02 | 39.18 ▲0.82 | 33.61 ▼4.27 |
Add New Post /wp-admin/post-new.php | 1,539 ▲13 | 23.48 ▲0.28 | 737.68 ▲37.83 | 61.49 ▲8.28 |
Media Library /wp-admin/upload.php | 1,409 ▲9 | 4.12 ▼0.09 | 100.47 ▼6.32 | 75.14 ▲27.23 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 75% from 4 tests
🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
These items require your attention
- This plugin does not fully uninstall, leaving 10 options in the database
- can_compress_scripts
- widget_recent-comments
- sad_post_title
- sad_post_devtools
- widget_theysaidso_widget
- widget_recent-posts
- sad_post_description
- sad_post_animation
- theysaidso_admin_options
- db_upgraded
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
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 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
- 2× PHP files trigger errors when accessed directly with GET requests:
- > PHP Fatal error
Uncaught Error: Call to undefined function add_action() in wp-content/plugins/simple-adblock-detector/sad_options.php:21
- > PHP Fatal error
Uncaught Error: Call to undefined function add_action() in wp-content/plugins/simple-adblock-detector/sad_options.php:21
- > PHP Fatal error
User-side errors Passed 1 test
🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
There were no browser issues found
Optimizations
Plugin configuration 90% from 29 tests
readme.txt Passed 16 tests
The readme.txt file is important because it is parsed by WordPress.org for the public listing of your plugin
3 plugin tags: adblock detectors, adblock, detect adblock plus
simple-adblock-detector/index.php 77% from 13 tests
The entry point to "Simple AdBlock Detector" version 1.0 is a PHP file that has certain tags in its header comment area
You should first fix the following items:
- Main file name: It is recommended to name the main PHP file as the plugin slug ("simple-adblock-detector.php" instead of "index.php")
- Description: The description should be shorter than 140 characters (currently 142 characters long)
- Requires at least: Required version must be the same as the one declared in readme.txt ("3.0.1" instead of "3.0")
Code Analysis Passed 3 tests
File types Passed 1 test
🔸 Test weight: 35 | Executable files are not allowed as they can serve as attack vectors
There were no executable files found in this plugin113 lines of code in 8 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 4 | 35 | 36 | 109 |
CSS | 3 | 0 | 6 | 3 |
JavaScript | 1 | 0 | 0 | 1 |
PHP code Passed 2 tests
This is a very shot review of cyclomatic complexity and code structure
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.10 |
Average class complexity | 0.00 |
▷ Minimum class complexity | 0.00 |
▷ Maximum class complexity | 0.00 |
Average method complexity | 0.00 |
▷ Minimum method complexity | 0.00 |
▷ Maximum method complexity | 0.00 |
Code structure | ||
---|---|---|
Namespaces | 0 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 0 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 0 | 0.00% |
▷ Final classes | 0 | 0.00% |
Methods | 0 | |
▷ Static methods | 0 | 0.00% |
▷ Public methods | 0 | 0.00% |
▷ Protected methods | 0 | 0.00% |
▷ Private methods | 0 | 0.00% |
Functions | 5 | |
▷ Named functions | 5 | 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 50% from 2 tests
Image compression 50% from 2 tests
Often times overlooked, PNG files can occupy unnecessary space in your plugin
6 PNG files occupy 0.52MB with 0.27MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
img/ico.png | 2.90KB | 1.80KB | ▼ 37.81% |
img/sad.png | 14.29KB | 5.75KB | ▼ 59.79% |
img/img.png | 4.95KB | 2.64KB | ▼ 46.63% |
img/icon-SAD.png | 8.70KB | 3.58KB | ▼ 58.89% |
img/sadback.png | 149.83KB | 61.44KB | ▼ 59.00% |