Benchmarks
Plugin footprint 83% from 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | Checking the installer triggered no errors
The plugin installed successfully, without throwing any errors or notices
Server metrics [RAM: ▲0.08MB] [CPU: ▼3.69ms] Passed 4 tests
Analyzing server-side resources used by QS Dark Mode Plugin
This plugin has minimal impact on server resources
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.54 ▲0.07 | 44.17 ▼3.04 |
Dashboard /wp-admin | 3.38 ▲0.07 | 51.10 ▲2.77 |
Posts /wp-admin/edit.php | 3.49 ▲0.13 | 51.58 ▼4.72 |
Add New Post /wp-admin/post-new.php | 5.99 ▲0.10 | 90.16 ▼9.77 |
Media Library /wp-admin/upload.php | 3.30 ▲0.07 | 42.47 ▲5.24 |
Dark Mode /wp-admin/admin.php?page=qs-dark-mode | 3.46 | 46.11 |
Server storage [IO: ▲1.15MB] [DB: ▲0.00MB] Passed 3 tests
A short overview of filesystem and database impact
There were no storage issued detected upon installing this plugin
Filesystem: 125 new files
Database: no new tables, 6 new options
New WordPress options |
---|
widget_recent-comments |
widget_recent-posts |
can_compress_scripts |
theysaidso_admin_options |
widget_theysaidso_widget |
db_upgraded |
Browser metrics Passed 4 tests
A check of browser resources used by QS Dark Mode Plugin
This plugin has a minimal impact on browser resources
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,868 ▲122 | 13.27 ▼1.12 | 1.75 ▼0.67 | 44.42 ▼1.46 |
Dashboard /wp-admin | 2,248 ▲60 | 4.88 ▼1.03 | 108.59 ▲3.78 | 86.03 ▲44.34 |
Posts /wp-admin/edit.php | 2,146 ▲57 | 2.07 ▲0.01 | 35.67 ▼5.68 | 38.91 ▲2.52 |
Add New Post /wp-admin/post-new.php | 6,418 ▲4,874 | 27.87 ▲9.33 | 877.93 ▲229.24 | 36.27 ▼20.04 |
Media Library /wp-admin/upload.php | 1,445 ▲57 | 4.25 ▲0.10 | 96.40 ▼14.32 | 72.74 ▲26.45 |
Dark Mode /wp-admin/admin.php?page=qs-dark-mode | 5,563 | 4.95 | 156.10 | 102.87 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 75% from 4 tests
🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
You still need to fix the following
- The uninstall procedure has failed, leaving 6 options in the database
- db_upgraded
- can_compress_scripts
- widget_recent-posts
- widget_theysaidso_widget
- widget_recent-comments
- theysaidso_admin_options
Smoke tests 25% from 4 tests
Server-side errors Passed 1 test
🔹 Test weight: 20 | A smoke test targeting server-side errors
Everything seems fine, however this is by no means an exhaustive test
SRP 0% from 2 tests
🔹 Tests weight: 20 | SRP (Single-Responsibility Principle) - PHP files must act as libraries and never output text or perform any action when accessed directly in a browser
Please fix the following items
- 1× PHP files perform the task of outputting text when accessed with GET requests:
- > /wp-content/plugins/qs-dark-mode/qs-dark-mode.php
- 24× GET requests to PHP files trigger server-side errors or Error 500 responses (only 10 are shown):
- > PHP Fatal error
Uncaught Error: Using $this when not in object context in wp-content/plugins/qs-dark-mode/app/Pages/views/option-part/images.php:2
- > PHP Fatal error
Uncaught Error: Call to undefined function esc_attr() in wp-content/plugins/qs-dark-mode/app/Base/views/presets/style2.php:5
- > PHP Fatal error
Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/qs-dark-mode/app/Utilities/Inc/Hooks.php:4
- > PHP Fatal error
Uncaught Error: Using $this when not in object context in wp-content/plugins/qs-dark-mode/app/Pages/views/option-part/color-preset.php:2
- > PHP Fatal error
Uncaught Error: Call to undefined function esc_url() in wp-content/plugins/qs-dark-mode/app/Pages/views/dashboard.php:12
- > PHP Fatal error
Uncaught Error: Call to undefined function esc_attr() in wp-content/plugins/qs-dark-mode/app/Base/views/presets/style1.php:1
- > PHP Fatal error
Uncaught Error: Class 'QSDarkMode\\Base\\BaseController' not found in wp-content/plugins/qs-dark-mode/app/Base/SettingsLinks.php:6
- > PHP Fatal error
Uncaught Error: Call to undefined function apply_filters() in wp-content/plugins/qs-dark-mode/app/Pages/options/custom_element.php:4
- > PHP Fatal error
Uncaught Error: Using $this when not in object context in wp-content/plugins/qs-dark-mode/app/Pages/views/option-part/advanced.php:2
- > PHP Fatal error
Uncaught Error: Call to undefined function esc_html__() in wp-content/plugins/qs-dark-mode/app/Pages/options/advanced.php:13
- > PHP Fatal error
User-side errors 0% from 1 test
🔹 Test weight: 20 | This is a shallow check for browser errors
Please take a look at the following user-side issues
- > GET request to /wp-admin/admin.php?page=qs-dark-mode
- > Rendering (warning) in unknown
/wp-admin/admin.php?page=qs-dark-mode 724 The specified value "" does not conform to the required format. The format is "#rrggbb" where rr, gg, bb are two-digit hexadecimal numbers.
- > GET request to /wp-admin/admin.php?page=qs-dark-mode
- > Rendering (warning) in unknown
/wp-admin/admin.php?page=qs-dark-mode 736 The specified value "" does not conform to the required format. The format is "#rrggbb" where rr, gg, bb are two-digit hexadecimal numbers.
- > GET request to /wp-admin/admin.php?page=qs-dark-mode
- > Rendering (warning) in unknown
/wp-admin/admin.php?page=qs-dark-mode 748 The specified value "" does not conform to the required format. The format is "#rrggbb" where rr, gg, bb are two-digit hexadecimal numbers.
- > GET request to /wp-admin/admin.php?page=qs-dark-mode
- > Rendering (warning) in unknown
/wp-admin/admin.php?page=qs-dark-mode 786 The specified value "" does not conform to the required format. The format is "#rrggbb" where rr, gg, bb are two-digit hexadecimal numbers.
- > GET request to /wp-admin/admin.php?page=qs-dark-mode
- > Rendering (warning) in unknown
/wp-admin/admin.php?page=qs-dark-mode 798 The specified value "" does not conform to the required format. The format is "#rrggbb" where rr, gg, bb are two-digit hexadecimal numbers.
- > GET request to /wp-admin/admin.php?page=qs-dark-mode
- > Rendering (warning) in unknown
/wp-admin/admin.php?page=qs-dark-mode 961 The specified value "" does not conform to the required format. The format is "#rrggbb" where rr, gg, bb are two-digit hexadecimal numbers.
- > GET request to /wp-admin/admin.php?page=qs-dark-mode
- > Rendering (warning) in unknown
/wp-admin/admin.php?page=qs-dark-mode 974 The specified value "" does not conform to the required format. The format is "#rrggbb" where rr, gg, bb are two-digit hexadecimal numbers.
- > GET request to /wp-admin/admin.php?page=qs-dark-mode
- > Rendering (warning) in unknown
/wp-admin/admin.php?page=qs-dark-mode 987 The specified value "" does not conform to the required format. The format is "#rrggbb" where rr, gg, bb are two-digit hexadecimal numbers.
- > GET request to /wp-admin/admin.php?page=qs-dark-mode
- > Rendering (warning) in unknown
/wp-admin/admin.php?page=qs-dark-mode 1000 The specified value "" does not conform to the required format. The format is "#rrggbb" where rr, gg, bb are two-digit hexadecimal numbers.
- > GET request to /wp-admin/admin.php?page=qs-dark-mode
- > Rendering (warning) in unknown
/wp-admin/admin.php?page=qs-dark-mode 1013 The specified value "" does not conform to the required format. The format is "#rrggbb" where rr, gg, bb are two-digit hexadecimal numbers.
- > GET request to /wp-admin/admin.php?page=qs-dark-mode
- > Rendering (warning) in unknown
/wp-admin/admin.php?page=qs-dark-mode 1026 The specified value "" does not conform to the required format. The format is "#rrggbb" where rr, gg, bb are two-digit hexadecimal numbers.
- > GET request to /wp-admin/admin.php?page=qs-dark-mode
- > Rendering (warning) in unknown
/wp-admin/admin.php?page=qs-dark-mode 1039 The specified value "" does not conform to the required format. The format is "#rrggbb" where rr, gg, bb are two-digit hexadecimal numbers.
Optimizations
Plugin configuration 93% from 29 tests
readme.txt 94% from 16 tests
Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
These attributes need your attention:
- Screenshots: These screenshots need descriptions #1, #2, #3, #4, #5, #6, #7, #8 in qs-dark-mode/assets to your readme.txt
qs-dark-mode/qs-dark-mode.php 92% from 13 tests
The entry point to "QS Dark Mode Plugin" version 2.8 is a PHP file that has certain tags in its header comment area
You should first fix the following items:
- Requires at least: The required version number did not match the one declared in readme.txt ("5.5" instead of "5.0")
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
Good job! No executable or dangerous file extensions detected19,424 lines of code in 99 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
CSS | 10 | 3,164 | 67 | 13,448 |
PHP | 53 | 1,234 | 355 | 3,831 |
JavaScript | 13 | 449 | 136 | 1,657 |
SVG | 16 | 0 | 1 | 213 |
JSON | 4 | 1 | 0 | 184 |
Sass | 3 | 6 | 0 | 91 |
PHP code Passed 2 tests
This is a very shot review of cyclomatic complexity and code structure
There were no cyclomatic complexity issued detected
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.50 |
Average class complexity | 11.65 |
▷ Minimum class complexity | 1.00 |
▷ Maximum class complexity | 47.00 |
Average method complexity | 3.20 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 18.00 |
Code structure | ||
---|---|---|
Namespaces | 7 | |
Interfaces | 0 | |
Traits | 7 | |
Classes | 13 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 13 | 100.00% |
▷ Final classes | 1 | 7.69% |
Methods | 98 | |
▷ Static methods | 26 | 26.53% |
▷ Public methods | 95 | 96.94% |
▷ Protected methods | 0 | 0.00% |
▷ Private methods | 3 | 3.06% |
Functions | 56 | |
▷ Named functions | 54 | 96.43% |
▷ Anonymous functions | 2 | 3.57% |
Constants | 11 | |
▷ Global constants | 11 | 100.00% |
▷ Class constants | 0 | 0.00% |
▷ Public constants | 0 | 0.00% |
Plugin size 50% from 2 tests
Image compression 50% from 2 tests
Often times overlooked, PNG files can occupy unnecessary space in your plugin
21 PNG files occupy 0.16MB with 0.08MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
assets/img/presets/style8.png | 16.05KB | 7.18KB | ▼ 55.27% |
assets/img/switchs/style2.png | 0.91KB | 0.54KB | ▼ 40.04% |
assets/img/switchs/style9.png | 0.82KB | 0.59KB | ▼ 28.11% |
assets/img/icon.png | 0.31KB | 0.28KB | ▼ 9.49% |
(invalid) assets/img/switchs/style1.png | 2.01KB | 0.00KB | ▼ 100.00% |