Benchmarks
Plugin footprint 83% from 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
This plugin's installer ran successfully
Server metrics [RAM: ▲2.21MB] [CPU: ▲170.19ms] Passed 4 tests
Analyzing server-side resources used by Dotdigital for WordPress
Normal server usage
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 4.89 ▲1.42 | 54.83 ▲13.59 |
Dashboard /wp-admin | 5.77 ▲2.47 | 387.06 ▲339.36 |
Posts /wp-admin/edit.php | 5.83 ▲2.47 | 258.78 ▲215.34 |
Add New Post /wp-admin/post-new.php | 8.39 ▲2.50 | 308.65 ▲211.71 |
Media Library /wp-admin/upload.php | 5.71 ▲2.48 | 276.12 ▲240.12 |
/wp-admin/admin.php?page=dm_form_settings | 5.65 | 475.86 |
Server storage [IO: ▲4.13MB] [DB: ▲0.00MB] Passed 3 tests
A short overview of filesystem and database impact
No storage issues were detected
Filesystem: 1,529 new files
Database: no new tables, 9 new options
New WordPress options |
---|
widget_recent-posts |
widget_theysaidso_widget |
widget_recent-comments |
widget_dotdigital-for-wordpress_widget_signup_form |
dm_API_messages |
db_upgraded |
can_compress_scripts |
theysaidso_admin_options |
widget_dm_widget |
Browser metrics Passed 4 tests
An overview of browser requirements for Dotdigital for WordPress
Normal browser usage
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,916 ▲154 | 13.77 ▼0.60 | 9.84 ▲8.09 | 48.03 ▲2.15 |
Dashboard /wp-admin | 2,235 ▲61 | 5.64 ▼0.01 | 83.38 ▼10.12 | 37.23 ▼8.12 |
Posts /wp-admin/edit.php | 2,142 ▲42 | 2.05 ▲0.05 | 39.27 ▲1.11 | 33.13 ▼1.96 |
Add New Post /wp-admin/post-new.php | 6,434 ▲4,899 | 29.32 ▲4.36 | 859.95 ▲251.03 | 38.17 ▼28.54 |
Media Library /wp-admin/upload.php | 1,441 ▲44 | 4.22 ▲0.04 | 94.88 ▼6.69 | 41.37 ▼1.78 |
/wp-admin/admin.php?page=dm_form_settings | 814 | 1.79 | 23.85 | 24.36 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 75% from 4 tests
🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
Please fix the following items
- Zombie WordPress options detected upon uninstall: 7 options
- widget_dotdigital-for-wordpress_widget_signup_form
- can_compress_scripts
- widget_recent-comments
- db_upgraded
- widget_recent-posts
- widget_theysaidso_widget
- theysaidso_admin_options
Smoke tests 25% from 4 tests
Server-side errors 0% from 1 test
🔹 Test weight: 20 | This is a shallow check for server-side errors
These server-side errors were triggered
- 2 occurences, only the last one shown
- > GET request to /wp-admin/admin.php?page=dm_form_settings
- > Warning in wp-includes/pluggable.php+1438
Cannot modify header information - headers already sent by (output started at wp-includes/script-loader.php:2838)
SRP 0% from 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
Almost there! Just fix the following items
- 1× PHP files output text when accessed directly:
- > /wp-content/plugins/dotmailer-sign-up-widget/admin/view/partials/dotdigital-wordpress-admin-settings-tab-links.php
- 402× PHP files trigger server errors when accessed directly (only 10 are shown):
- > PHP Fatal error
Uncaught LogicException: You cannot use "Http\\Message\\MessageFactory\\GuzzleStreamFactory" as the "php-http/message-factory" package is not installed. Try running "composer require php-http/message-factory". Note that this package is deprecated, use "psr/http-factory" instead in wp-content/plugins/dotmailer-sign-up-widget/vendor/php-http/message/src/StreamFactory/GuzzleStreamFactory.php:8
- > PHP Fatal error
Uncaught Error: Interface 'Dotdigital_WordPress_Vendor\\Symfony\\Component\\Translation\\TranslatorBagInterface' not found in wp-content/plugins/dotmailer-sign-up-widget/vendor/symfony/translation/TranslatorBag.php:15
- > PHP Fatal error
Uncaught Error: Call to undefined function Dotdigital_WordPress_Vendor\\esc_attr() in wp-content/plugins/dotmailer-sign-up-widget/public/view/widget/dotdigital-wordpress-widget-sign-up.php:25
- > PHP Fatal error
Uncaught Error: Interface 'Dotdigital_WordPress_Vendor\\Psr\\Http\\Message\\StreamInterface' not found in wp-content/plugins/dotmailer-sign-up-widget/vendor/guzzlehttp/psr7/src/PumpStream.php:17
- > PHP Fatal error
Uncaught Error: Call to undefined function Dotdigital_WordPress_Vendor\\esc_html() in wp-content/plugins/dotmailer-sign-up-widget/admin/view/form/dotdigital-wordpress-setting-form-radio-group.php:14
- > PHP Fatal error
Uncaught Error: Interface 'Dotdigital_WordPress_Vendor\\Http\\Client\\HttpClient' not found in wp-content/plugins/dotmailer-sign-up-widget/vendor/php-http/client-common/src/HttpClientRouterInterface.php:17
- > PHP Fatal error
Uncaught Error: Class 'Dotdigital_WordPress_Vendor\\Http\\Message\\Encoding\\FilteredStream' not found in wp-content/plugins/dotmailer-sign-up-widget/vendor/php-http/message/src/Encoding/DechunkStream.php:12
- > PHP Fatal error
Uncaught Error: Class 'Dotdigital_WordPress_Vendor\\Symfony\\Component\\Translation\\Extractor\\AbstractFileExtractor' not found in wp-content/plugins/dotmailer-sign-up-widget/vendor/symfony/translation/Extractor/PhpExtractor.php:20
- > PHP Fatal error
Uncaught Error: Interface 'Dotdigital_WordPress_Vendor\\PHPStan\\Reflection\\MethodsClassReflectionExtension' not found in wp-content/plugins/dotmailer-sign-up-widget/vendor/nesbot/carbon/src/Carbon/PHPStan/MacroExtension.php:25
- > PHP Fatal error
Uncaught Error: Interface 'Dotdigital_WordPress_Vendor\\Http\\Client\\Common\\HttpClientPool' not found in wp-content/plugins/dotmailer-sign-up-widget/vendor/php-http/client-common/src/HttpClientPool/HttpClientPool.php:16
- > PHP Fatal error
User-side errors Passed 1 test
🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
No browser errors were detected
Optimizations
Plugin configuration 93% from 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
2 plugin tags: newsletter signup, email marketing
dotmailer-sign-up-widget/dm_signup_form.php 85% from 13 tests
The principal PHP file in "Dotdigital for WordPress" v. 7.1.0 is loaded by WordPress automatically on each request
The following require your attention:
- Text Domain: You no longer need to specify the text domain since WordPress 4.6; it must be the same as the plugin slug
- Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("dotmailer-sign-up-widget.php" instead of "dm_signup_form.php")
Code Analysis 97% from 3 tests
File types Passed 1 test
🔸 Test weight: 35 | A short glimpse at programming languages used with this plugin and a check that no dangerous files are present
Success! There were no dangerous files found in this plugin47,222 lines of code in 1,299 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 1,256 | 2,669 | 38,805 | 40,516 |
JSON | 31 | 0 | 0 | 3,669 |
XSD | 3 | 92 | 48 | 2,803 |
JavaScript | 4 | 10 | 1 | 159 |
CSS | 5 | 17 | 10 | 75 |
PHP code 50% from 2 tests
An overview of cyclomatic complexity and code structure
It is recommended to fix the following
- Method cyclomatic complexity should be reduced to less than 100 (currently 140)
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.44 |
Average class complexity | 9.81 |
▷ Minimum class complexity | 1.00 |
▷ Maximum class complexity | 351.00 |
Average method complexity | 2.58 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 140.00 |
Code structure | ||
---|---|---|
Namespaces | 104 | |
Interfaces | 77 | |
Traits | 44 | |
Classes | 452 | |
▷ Abstract classes | 23 | 5.09% |
▷ Concrete classes | 429 | 94.91% |
▷ Final classes | 139 | 32.40% |
Methods | 3,400 | |
▷ Static methods | 571 | 16.79% |
▷ Public methods | 2,870 | 84.41% |
▷ Protected methods | 184 | 5.41% |
▷ Private methods | 346 | 10.18% |
Functions | 582 | |
▷ Named functions | 188 | 32.30% |
▷ Anonymous functions | 394 | 67.70% |
Constants | 225 | |
▷ Global constants | 15 | 6.67% |
▷ Class constants | 210 | 93.33% |
▷ Public constants | 182 | 86.67% |
Plugin size Passed 2 tests
Image compression Passed 2 tests
Often times overlooked, PNG files can occupy unnecessary space in your plugin
3 PNG files occupy 0.01MB with 0.01MB in potential savings
Potential savings
Compression of 3 random PNG files using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
assets/dotdigital-applogo-32x32.png | 4.25KB | 1.79KB | ▼ 57.78% |
assets/large.png | 0.26KB | 0.10KB | ▼ 60.31% |
assets/dotdigital-logo.png | 5.69KB | 3.38KB | ▼ 40.56% |