Benchmarks
Plugin footprint 83% from 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
This plugin's installer ran successfully
Server metrics [RAM: ▲0.19MB] [CPU: ▼2.70ms] Passed 4 tests
Analyzing server-side resources used by Plugin Name: Device Theme Switcher
This plugin has minimal impact on server resources
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.87 ▲0.41 | 49.42 ▼0.01 |
Dashboard /wp-admin | 3.49 ▲0.18 | 47.09 ▼0.09 |
Posts /wp-admin/edit.php | 3.60 ▲0.24 | 51.47 ▲5.36 |
Add New Post /wp-admin/post-new.php | 6.07 ▲0.18 | 86.80 ▼16.05 |
Media Library /wp-admin/upload.php | 3.41 ▲0.18 | 38.67 ▲6.21 |
Device Themes /wp-admin/themes.php?page=device-themes | 3.40 | 37.28 |
Server storage [IO: ▲0.13MB] [DB: ▲0.00MB] Passed 3 tests
Analyzing filesystem and database footprints of this plugin
No storage issues were detected
Filesystem: 16 new files
Database: no new tables, 11 new options
New WordPress options |
---|
widget_recent-posts |
db_upgraded |
widget_theysaidso_widget |
widget_dts_return_to_mobile_website |
widget_dts_view_full_website |
can_compress_scripts |
dts_cookie_name |
theysaidso_admin_options |
dts_version |
widget_recent-comments |
... |
Browser metrics Passed 4 tests
Plugin Name: Device Theme Switcher: 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,833 ▲87 | 13.32 ▼1.33 | 1.84 ▼0.02 | 38.92 ▲0.19 |
Dashboard /wp-admin | 2,217 ▲29 | 4.85 ▼0.03 | 101.66 ▼10.10 | 40.07 ▲0.80 |
Posts /wp-admin/edit.php | 2,094 ▲5 | 2.01 ▲0.04 | 34.09 ▼1.48 | 33.45 ▼0.43 |
Add New Post /wp-admin/post-new.php | 1,521 ▲7 | 23.42 ▲5.69 | 652.88 ▼7.79 | 50.50 ▼14.85 |
Media Library /wp-admin/upload.php | 1,399 ▲14 | 4.24 ▲0.00 | 99.04 ▼3.35 | 43.14 ▲0.13 |
Device Themes /wp-admin/themes.php?page=device-themes | 1,151 | 2.06 | 26.86 | 32.80 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 75% from 4 tests
🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
The following items require your attention
- Zombie WordPress options were found after uninstall: 6 options
- theysaidso_admin_options
- widget_recent-comments
- db_upgraded
- can_compress_scripts
- widget_recent-posts
- widget_theysaidso_widget
Smoke tests Passed 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)
Even though no errors were found, this is by no means an exhaustive test
SRP Passed 2 tests
🔹 Tests weight: 20 | It is important to ensure that your PHP files perform no action when accessed directly, respecting the single-responsibility principle
Congratulations! This plugin passed the SRP test
User-side errors Passed 1 test
🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
Everything seems fine, but this is not an exhaustive test
Optimizations
Plugin configuration 90% from 29 tests
readme.txt 88% from 16 tests
The readme.txt file is undoubtedly the most important file in your plugin, preparing it for public listing on WordPress.org
Attributes that require attention:
- Plugin Name: "Plugin Name" should be replaced with the name of your plugin on the first line (
=== Plugin Name: Device Theme Switcher===
) - Tags: Too many tags (14 tag instead of maximum 10); only the first 5 tags are used in your directory listing
device-theme-switcher/dts_controller.php 92% from 13 tests
The main file in "Plugin Name: Device Theme Switcher" v. 3.0.2 serves as a complement to information provided in readme.txt and as the entry point to the plugin
Please make the necessary changes and fix the following:
- Main file name: It is recommended to name the main PHP file as the plugin slug ("device-theme-switcher.php" instead of "dts_controller.php")
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 plugin1,708 lines of code in 14 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 12 | 585 | 1,196 | 1,706 |
CSS | 1 | 0 | 0 | 1 |
JavaScript | 1 | 0 | 3 | 1 |
PHP code Passed 2 tests
This is a very shot 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.55 |
Average class complexity | 40.12 |
▷ Minimum class complexity | 1.00 |
▷ Maximum class complexity | 223.00 |
Average method complexity | 3.75 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 21.00 |
Code structure | ||
---|---|---|
Namespaces | 0 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 8 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 8 | 100.00% |
▷ Final classes | 0 | 0.00% |
Methods | 114 | |
▷ Static methods | 18 | 15.79% |
▷ Public methods | 114 | 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 | 3 | |
▷ Global constants | 3 | 100.00% |
▷ Class constants | 0 | 0.00% |
▷ Public constants | 0 | 0.00% |
Plugin size Passed 2 tests
Image compression Passed 2 tests
All PNG images should be compressed to minimize bandwidth usage for end users
No PNG images were found in this plugin