Benchmarks
Plugin footprint 83% from 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | Checking the installer triggered no errors
Installer ran successfully
Server metrics [RAM: ▲0.30MB] [CPU: ▼3.32ms] Passed 4 tests
A check of server-side resources used by Restrict Widgets
This plugin has minimal impact on server resources
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.75 ▲0.29 | 45.13 ▼3.11 |
Dashboard /wp-admin | 3.60 ▲0.30 | 62.95 ▲5.89 |
Posts /wp-admin/edit.php | 3.72 ▲0.36 | 53.70 ▲0.52 |
Add New Post /wp-admin/post-new.php | 6.19 ▲0.30 | 90.03 ▼16.57 |
Media Library /wp-admin/upload.php | 3.54 ▲0.31 | 46.02 ▲8.83 |
Restrict Widgets /wp-admin/options-general.php?page=restrict-widgets | 3.48 | 36.23 |
Server storage [IO: ▲0.21MB] [DB: ▲0.00MB] Passed 3 tests
Filesystem and database footprint
No storage issues were detected
Filesystem: 59 new files
Database: no new tables, 6 new options
New WordPress options |
---|
widget_theysaidso_widget |
theysaidso_admin_options |
widget_recent-comments |
can_compress_scripts |
db_upgraded |
widget_recent-posts |
Browser metrics Passed 4 tests
An overview of browser requirements for Restrict Widgets
There were no issues detected in relation to browser resource usage
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,793 ▲32 | 14.35 ▼0.36 | 1.70 ▼0.42 | 47.05 ▲0.13 |
Dashboard /wp-admin | 2,202 ▲25 | 5.63 ▲0.10 | 89.03 ▼11.49 | 38.96 ▼8.86 |
Posts /wp-admin/edit.php | 2,107 ▲7 | 2.00 ▼0.01 | 36.09 ▼2.28 | 37.25 ▲1.53 |
Add New Post /wp-admin/post-new.php | 1,531 ▲4 | 23.22 ▲0.13 | 676.11 ▼7.57 | 51.86 ▼1.30 |
Media Library /wp-admin/upload.php | 1,407 ▲4 | 4.29 ▲0.10 | 98.79 ▼3.75 | 43.07 ▼1.40 |
Restrict Widgets /wp-admin/options-general.php?page=restrict-widgets | 1,400 | 2.40 | 41.89 | 39.51 |
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
These items require your attention
- The uninstall procedure has failed, leaving 6 options in the database
- widget_recent-comments
- can_compress_scripts
- widget_theysaidso_widget
- widget_recent-posts
- db_upgraded
- theysaidso_admin_options
Smoke tests 75% from 4 tests
Server-side errors 0% from 1 test
🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Almost there, just fix the following server-side errors
- > GET request to /wp-admin/options-general.php?page=restrict-widgets
- > User deprecated in wp-includes/functions.php+5463
Function screen_icon is deprecated since version 3.8.0 with no alternative available.
- > GET request to /wp-admin/options-general.php?page=restrict-widgets
- > User deprecated in wp-includes/functions.php+5463
Function get_screen_icon is deprecated since version 3.8.0 with no alternative available.
SRP Passed 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
Everything seems fine, however this is by no means an exhaustive test
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 93% from 29 tests
readme.txt 94% from 16 tests
You should put a lot of thought into formatting readme.txt as it is used by WordPress.org to prepare the public listing of your plugin
These attributes need your attention:
- Tags: There are too many tags (18 tag instead of maximum 10)
restrict-widgets/restrict-widgets.php 92% from 13 tests
The main file in "Restrict Widgets" v. 1.3.1 serves as a complement to information provided in readme.txt and as the entry point to the plugin
The following require your attention:
- Description: The description should be shorter than 140 characters (currently 143 characters long)
Code Analysis 97% from 3 tests
File types Passed 1 test
🔸 Test weight: 35 | An overview of files in this plugin; executable files are not allowed
Success! There were no dangerous files found in this plugin1,802 lines of code in 53 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 2 | 286 | 218 | 1,156 |
CSS | 2 | 14 | 9 | 441 |
PO File | 1 | 41 | 42 | 106 |
JavaScript | 48 | 60 | 62 | 99 |
PHP code 50% from 2 tests
Analyzing cyclomatic complexity and code structure
Please fix the following
- Please reduce cyclomatic complexity of methods to less than 100 (currently 143)
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.91 |
Average class complexity | 380.00 |
▷ Minimum class complexity | 380.00 |
▷ Maximum class complexity | 380.00 |
Average method complexity | 10.47 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 143.00 |
Code structure | ||
---|---|---|
Namespaces | 0 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 1 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 1 | 100.00% |
▷ Final classes | 1 | 100.00% |
Methods | 40 | |
▷ Static methods | 1 | 2.50% |
▷ Public methods | 34 | 85.00% |
▷ Protected methods | 0 | 0.00% |
▷ Private methods | 6 | 15.00% |
Functions | 1 | |
▷ Named functions | 1 | 100.00% |
▷ Anonymous functions | 0 | 0.00% |
Constants | 3 | |
▷ Global constants | 2 | 66.67% |
▷ Class constants | 1 | 33.33% |
▷ Public constants | 1 | 100.00% |
Plugin size Passed 2 tests
Image compression Passed 2 tests
It is recommended to compress PNG files in your plugin to minimize bandwidth usage
3 compressed PNG files occupy 0.00MB
Potential savings
Compression of 3 random PNG files using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
images/chosen-sprite.png | 0.63KB | 0.88KB | 0.00% |
images/chosen-sprite@2x.png | 0.85KB | 0.83KB | ▼ 3.10% |
images/logo-dfactory.png | 2.92KB | 1.92KB | ▼ 34.20% |