Benchmarks
Plugin footprint 83% from 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
Install script ran successfully
Server metrics [RAM: ▲3.67MB] [CPU: ▼272.13ms] Passed 4 tests
Server-side resources used by stats4wp
No issues were detected with server-side resource usage
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 7.22 ▲3.70 | 127.55 ▲66.84 |
Dashboard /wp-admin | 7.07 ▲3.66 | 81.04 ▲41.66 |
Posts /wp-admin/edit.php | 7.35 ▲3.71 | 66.92 ▲25.87 |
Add New Post /wp-admin/post-new.php | 10.59 ▲3.62 | 127.64 ▼1,172.13 |
Media Library /wp-admin/upload.php | 7.01 ▲3.72 | 62.91 ▲16.08 |
Pages /wp-admin/admin.php?page=stats4wp_pages | 7.08 | 61.74 |
Dashboard /wp-admin/admin.php?page=stats4wp_plugin | 7.10 | 69.50 |
Settings /wp-admin/admin.php?page=stats4wp_settings | 7.03 | 51.03 |
CSV Export /wp-admin/admin.php?page=stats4wp_cvsexport | 7.00 | 50.40 |
Visitors /wp-admin/admin.php?page=stats4wp_visitors | 7.11 | 61.47 |
Server storage [IO: ▲11.26MB] [DB: ▲0.01MB] Passed 3 tests
A short overview of filesystem and database impact
No storage issues were detected
Filesystem: 295 new files
Database: 3 new tables, 2 new options
New tables |
---|
wp_stats4wp_useronline |
wp_stats4wp_visitor |
wp_stats4wp_pages |
New WordPress options |
---|
widget_stats4wp_cpt_visitors_widget |
stats4wp_plugin |
Browser metrics Passed 4 tests
An overview of browser requirements for stats4wp
This plugin has a minimal impact on browser resources
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 4,029 ▲307 | 16.33 ▲0.81 | 8.38 ▲1.03 | 3.47 ▲0.70 |
Dashboard /wp-admin | 3,118 ▲241 | 7.51 ▲1.15 | 159.52 ▼8.20 | 199.22 ▲10.82 |
Posts /wp-admin/edit.php | 2,766 ▲75 | 3.42 ▼0.00 | 79.07 ▲6.12 | 163.25 ▼3.63 |
Add New Post /wp-admin/post-new.php | 1,799 ▲159 | 22.94 ▲2.57 | 529.87 ▼41.98 | 182.28 ▼17.96 |
Media Library /wp-admin/upload.php | 1,777 ▲85 | 6.23 ▲0.51 | 161.58 ▼34.29 | 231.28 ▼53.84 |
Pages /wp-admin/admin.php?page=stats4wp_pages | 1,482 | 3.48 | 66.97 | 174.44 |
Dashboard /wp-admin/admin.php?page=stats4wp_plugin | 2,374 | 5.64 | 211.40 | 295.57 |
Settings /wp-admin/admin.php?page=stats4wp_settings | 2,039 | 3.51 | 64.87 | 175.29 |
CSV Export /wp-admin/admin.php?page=stats4wp_cvsexport | 1,265 | 3.35 | 69.46 | 142.99 |
Visitors /wp-admin/admin.php?page=stats4wp_visitors | 1,916 | 5.73 | 302.95 | 176.49 |
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 1 option in the database
- widget_stats4wp_cpt_visitors_widget
Smoke tests 50% from 4 tests
Server-side errors Passed 1 test
🔹 Test weight: 20 | A smoke test targeting server-side errors
Even though everything seems fine, this is not an exhaustive test
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
Almost there! Just fix the following items
- 5× PHP files perform the task of outputting text when accessed with GET requests:
- > /wp-content/plugins/stats4wp/templates-part/footer.php
- > /wp-content/plugins/stats4wp/vendor/whichbrowser/parser/bin/update-profiles.php
- > /wp-content/plugins/stats4wp/vendor/whichbrowser/parser/bin/update-browser-ids.php
- > /wp-content/plugins/stats4wp/vendor/whichbrowser/parser/bin/update-chrome.php
- > /wp-content/plugins/stats4wp/stats4wp.php
- 122× PHP files trigger server errors when accessed directly (only 10 are shown):
- > PHP Fatal error
Uncaught Error: Class 'WhichBrowser\\Data\\BuildIds' not found in wp-content/plugins/stats4wp/vendor/whichbrowser/parser/data/build-android.php:5
- > PHP Fatal error
Uncaught Error: Class 'WhichBrowser\\Data\\DeviceModels' not found in wp-content/plugins/stats4wp/vendor/whichbrowser/parser/data/indices/models-bada.php:5
- > PHP Fatal error
Uncaught Error: Class 'WhichBrowser\\Model\\Primitive\\Base' not found in wp-content/plugins/stats4wp/vendor/whichbrowser/parser/src/Model/Version.php:7
- > PHP Fatal error
Trait 'WhichBrowser\\Analyser\\Header\\Useragent\\Os' not found in wp-content/plugins/stats4wp/vendor/whichbrowser/parser/src/Analyser/Header/Useragent.php on line 5
- > PHP Fatal error
Uncaught Error: Class 'WhichBrowser\\Constants\\DeviceType' not found in wp-content/plugins/stats4wp/vendor/whichbrowser/parser/data/models-ios.php:10
- > PHP Fatal error
Uncaught Error: Class 'WhichBrowser\\Data\\DeviceModels' not found in wp-content/plugins/stats4wp/vendor/whichbrowser/parser/data/indices/models-wm.php:5
- > PHP Fatal error
Uncaught Error: Class 'WhichBrowser\\Data\\DeviceModels' not found in wp-content/plugins/stats4wp/vendor/whichbrowser/parser/data/models-brew.php:5
- > PHP Fatal error
Uncaught Error: Class 'STATS4WP\\Core\\BaseController' not found in wp-content/plugins/stats4wp/inc/Ui/Pages.php:16
- > PHP Fatal error
Uncaught Error: Class 'WhichBrowser\\Data\\DeviceModels' not found in wp-content/plugins/stats4wp/vendor/whichbrowser/parser/data/models-s40.php:5
- > PHP Fatal error
Uncaught Error: Class 'STATS4WP\\Core\\DB' not found in wp-content/plugins/stats4wp/templates-part/visitor/location.php:16
- > 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 97% from 29 tests
readme.txt 94% from 16 tests
The readme.txt file uses markdown syntax to describe your plugin to the world
Attributes that require attention:
- Tags: You are using too many tags: 29 tag instead of maximum 10
stats4wp/stats4wp.php Passed 13 tests
The primary PHP file in "stats4wp" version 1.3.3 is used by WordPress to initiate all plugin functionality
24 characters long description:
Statistics For WorPress.
Code Analysis 97% from 3 tests
File types Passed 1 test
🔸 Test weight: 35 | A short review of files and their extensions; it is not recommended to include executable files
No dangerous file extensions were detected76,322 lines of code in 237 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 213 | 4,978 | 2,425 | 59,859 |
JavaScript | 4 | 83 | 42 | 13,257 |
PO File | 2 | 406 | 496 | 889 |
Markdown | 6 | 346 | 0 | 740 |
C | 1 | 118 | 25 | 668 |
CSS | 4 | 136 | 54 | 525 |
JSON | 4 | 7 | 0 | 285 |
XML | 1 | 4 | 0 | 59 |
m4 | 1 | 8 | 0 | 32 |
C/C++ Header | 1 | 4 | 12 | 8 |
PHP code 50% from 2 tests
Cyclomatic complexity and code structure are the fingerprint of this plugin
The following items need your attention
- Please reduce cyclomatic complexity of methods to less than 100 (currently 107)
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.46 |
Average class complexity | 25.58 |
▷ Minimum class complexity | 1.00 |
▷ Maximum class complexity | 484.00 |
Average method complexity | 6.72 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 107.00 |
Code structure | ||
---|---|---|
Namespaces | 20 | |
Interfaces | 4 | |
Traits | 25 | |
Classes | 79 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 79 | 100.00% |
▷ Final classes | 1 | 1.27% |
Methods | 472 | |
▷ Static methods | 89 | 18.86% |
▷ Public methods | 261 | 55.30% |
▷ Protected methods | 0 | 0.00% |
▷ Private methods | 211 | 44.70% |
Functions | 28 | |
▷ Named functions | 13 | 46.43% |
▷ Anonymous functions | 15 | 53.57% |
Constants | 103 | |
▷ Global constants | 6 | 5.83% |
▷ Class constants | 97 | 94.17% |
▷ Public constants | 81 | 83.51% |
Plugin size 50% from 2 tests
Image compression 50% from 2 tests
It is recommended to compress PNG files in your plugin to minimize bandwidth usage
46 PNG files occupy 0.82MB with 0.22MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
assets/images/screenshot-6.png | 11.07KB | 6.50KB | ▼ 41.30% |
assets/images/logo-menu.png | 11.84KB | 0.81KB | ▼ 93.14% |
assets/images/search-engine/clearch.png | 0.29KB | 0.29KB | 0.00% |
assets/images/browser/Firefox%20Mobile.png | 0.80KB | 0.88KB | 0.00% |
assets/images/browser/UC%20Browser.png | 0.80KB | 0.93KB | 0.00% |