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
The plugin installed gracefully, with no errors
Server metrics [RAM: ▲0.04MB] [CPU: ▼1.55ms] Passed 4 tests
Server-side resources used by Device Detect
This plugin has minimal impact on server resources
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.49 ▲0.03 | 36.70 ▼0.91 |
Dashboard /wp-admin | 3.35 ▲0.04 | 45.61 ▼1.27 |
Posts /wp-admin/edit.php | 3.40 ▲0.04 | 50.03 ▼1.85 |
Add New Post /wp-admin/post-new.php | 5.93 ▲0.04 | 97.51 ▲8.19 |
Media Library /wp-admin/upload.php | 3.27 ▲0.04 | 33.68 ▼2.17 |
Server storage [IO: ▲0.10MB] [DB: ▲0.00MB] Passed 3 tests
Filesystem and database footprint
This plugin was installed successfully
Filesystem: 11 new files
Database: no new tables, 6 new options
New WordPress options |
---|
widget_recent-posts |
widget_theysaidso_widget |
can_compress_scripts |
db_upgraded |
widget_recent-comments |
theysaidso_admin_options |
Browser metrics Passed 4 tests
Device Detect: an overview of browser usage
This plugin renders optimally with no browser resource issues detected
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,800 ▲54 | 13.20 ▼1.38 | 1.51 ▼0.07 | 42.11 ▲0.77 |
Dashboard /wp-admin | 2,206 ▲18 | 4.88 ▼0.98 | 111.15 ▲12.55 | 39.97 ▼0.63 |
Posts /wp-admin/edit.php | 2,092 ▲3 | 2.03 ▼0.01 | 39.98 ▲3.34 | 34.61 ▲2.75 |
Add New Post /wp-admin/post-new.php | 6,252 ▲4,738 | 26.29 ▲8.83 | 847.98 ▲126.26 | 60.01 ▲6.59 |
Media Library /wp-admin/upload.php | 1,388 ▼0 | 4.22 ▼0.01 | 94.72 ▼14.98 | 41.20 ▼4.38 |
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
The following items require your attention
- This plugin does not fully uninstall, leaving 6 options in the database
- widget_recent-comments
- theysaidso_admin_options
- can_compress_scripts
- widget_theysaidso_widget
- widget_recent-posts
- db_upgraded
Smoke tests 75% from 4 tests
Server-side errors Passed 1 test
🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
Everything seems fine, however this is by no means 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
- 3× PHP files perform the task of outputting text when accessed with GET requests:
- > /wp-content/plugins/device-detect/index.php
- > /wp-content/plugins/device-detect/libraries/index.php
- > /wp-content/plugins/device-detect/languages/index.php
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 Passed 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
No tags were detected
device-detect/device-detect.php Passed 13 tests
The primary PHP file in "Device Detect" version 1.4.6 is used by WordPress to initiate all plugin functionality
116 characters long description:
Allows you to detect the device of the user, and to display some contents only for the phones, tablets or computers.
Code Analysis Passed 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 plugin814 lines of code in 5 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 4 | 199 | 871 | 784 |
PO File | 1 | 6 | 0 | 30 |
PHP code Passed 2 tests
A short review of cyclomatic complexity and code structure
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.79 |
Average class complexity | 139.00 |
▷ Minimum class complexity | 139.00 |
▷ Maximum class complexity | 139.00 |
Average method complexity | 4.83 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 78.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 | 36 | |
▷ Static methods | 9 | 25.00% |
▷ Public methods | 33 | 91.67% |
▷ Protected methods | 2 | 5.56% |
▷ Private methods | 1 | 2.78% |
Functions | 15 | |
▷ Named functions | 14 | 93.33% |
▷ Anonymous functions | 1 | 6.67% |
Constants | 16 | |
▷ Global constants | 7 | 43.75% |
▷ Class constants | 9 | 56.25% |
▷ Public constants | 9 | 100.00% |
Plugin size Passed 2 tests
Image compression Passed 2 tests
PNG files should be compressed to save space and minimize bandwidth usage
There were not PNG files found in your plugin