Benchmarks
Plugin footprint 40% from 16 tests
Installer 0% from 1 test
🔺 Critical test (weight: 50) | The install procedure must perform silently
It is recommended to fix the following installer errors
- Install procedure had errors
- > Deprecated in wp-content/plugins/stats-widget/stats-widget.php+28
Methods with the same name as their class will not be constructors in a future version of PHP; Widget_SiteStats has a deprecated constructor
Server metrics [RAM: ▼1.71MB] [CPU: ▼50.45ms] Passed 4 tests
Analyzing server-side resources used by Stats Widget
No issues were detected with server-side resource usage
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 2.28 ▼1.18 | 8.52 ▼30.24 |
Dashboard /wp-admin | 2.29 ▼1.01 | 9.38 ▼37.09 |
Posts /wp-admin/edit.php | 2.29 ▼1.06 | 9.91 ▼41.06 |
Add New Post /wp-admin/post-new.php | 2.29 ▼3.59 | 11.34 ▼93.39 |
Media Library /wp-admin/upload.php | 2.29 ▼0.94 | 10.44 ▼21.64 |
Server storage [IO: ▲0.04MB] [DB: ▲0.00MB] Passed 3 tests
Analyzing filesystem and database footprints of this plugin
No storage issues were detected
Filesystem: 4 new files
Database: no new tables, 7 new options
New WordPress options |
---|
widget_recent-comments |
widget_theysaidso_widget |
theysaidso_admin_options |
db_upgraded |
widget_recent-posts |
widget_sitestats |
can_compress_scripts |
Browser metrics Passed 4 tests
Checking browser requirements for Stats Widget
Minimal impact on browser resources
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,802 ▲67 | 13.20 ▼1.17 | 1.66 ▼0.24 | 38.99 ▼11.03 |
Dashboard /wp-admin | 2,206 ▲15 | 4.84 ▼0.05 | 112.37 ▲7.27 | 42.26 ▼1.96 |
Posts /wp-admin/edit.php | 2,092 ▼0 | 1.99 ▼0.05 | 34.65 ▼6.11 | 29.58 ▼4.76 |
Add New Post /wp-admin/post-new.php | 1,533 ▼3 | 23.14 ▼0.06 | 650.57 ▲18.32 | 51.67 ▼4.58 |
Media Library /wp-admin/upload.php | 1,385 ▼3 | 4.30 ▲0.07 | 95.31 ▼5.22 | 40.04 ▼4.40 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 50% from 4 tests
🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
The following items require your attention
- Uninstall procedure had uncaught errors
- > User deprecated in wp-includes/functions.php+5546
The called constructor method for WP_Widget class in Widget_SiteStats is deprecated since version 4.3.0! Use __construct() instead.
- Zombie WordPress options were found after uninstall: 7 options
- widget_sitestats
- theysaidso_admin_options
- db_upgraded
- can_compress_scripts
- widget_recent-posts
- widget_theysaidso_widget
- widget_recent-comments
Smoke tests 75% from 4 tests
Server-side errors Passed 1 test
🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Even though everything seems fine, this is not an exhaustive test
SRP 50% 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
Almost there! Just fix the following items
- 1× PHP files trigger server errors when accessed directly:
- > PHP Fatal error
Uncaught Error: Class 'WP_Widget' not found in wp-content/plugins/stats-widget/stats-widget.php:28
- > PHP Fatal error
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)
No browser issues were found
Optimizations
Plugin configuration 90% from 29 tests
readme.txt 81% from 16 tests
Don't ignore readme.txt as it is the file that instructs WordPress.org on how to present your plugin to the world
Attributes that require attention:
- Screenshots: Please add an image for screenshot #1 (widget sidebar view.)
- Contributors: No tags were detected
- Contributors: The plugin contributors field is not present
stats-widget/stats-widget.php Passed 13 tests
"Stats Widget" version 1.0's main PHP file describes plugin functionality and also serves as the entry point to any WordPress functionality
135 characters long description:
Widget to display stats on your site to guests such as the # total of pages, posts ,comments , tags and categories created on the site.
Code Analysis Passed 3 tests
File types Passed 1 test
🔸 Test weight: 35 | There should be no dangerous file extensions present in any WordPress plugin
No dangerous file extensions were detected78 lines of code in 2 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 1 | 25 | 20 | 65 |
CSS | 1 | 4 | 0 | 13 |
PHP code Passed 2 tests
A brief analysis of cyclomatic complexity and code structure for this plugin
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.07 |
Average class complexity | 4.00 |
▷ Minimum class complexity | 4.00 |
▷ Maximum class complexity | 4.00 |
Average method complexity | 1.75 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 3.00 |
Code structure | ||
---|---|---|
Namespaces | 0 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 1 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 1 | 100.00% |
▷ Final classes | 0 | 0.00% |
Methods | 4 | |
▷ Static methods | 0 | 0.00% |
▷ Public methods | 4 | 100.00% |
▷ Protected methods | 0 | 0.00% |
▷ Private methods | 0 | 0.00% |
Functions | 3 | |
▷ Named functions | 3 | 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 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.04MB with 0.02MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
screenshot-1.png.png | 38.18KB | 21.54KB | ▼ 43.57% |