Benchmarks
Plugin footprint 83% from 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | The install procedure must perform silently
Installer ran successfully
Server metrics [RAM: ▲0.03MB] [CPU: ▼8.50ms] Passed 4 tests
This is a short check of server-side resources used by Emergency Alerts
This plugin has minimal impact on server resources
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.43 ▼0.04 | 32.36 ▼10.63 |
Dashboard /wp-admin | 3.35 ▲0.05 | 50.08 ▼7.51 |
Posts /wp-admin/edit.php | 3.40 ▲0.05 | 52.60 ▼1.41 |
Add New Post /wp-admin/post-new.php | 5.93 ▲0.05 | 87.46 ▼14.43 |
Media Library /wp-admin/upload.php | 3.27 ▲0.04 | 37.20 ▼0.98 |
Emergency Alert /wp-admin/options-general.php?page=wpm-ea-settings | 3.30 | 41.57 |
Server storage [IO: ▲0.15MB] [DB: ▲0.00MB] Passed 3 tests
Filesystem and database footprint
This plugin was installed successfully
Filesystem: 13 new files
Database: no new tables, 6 new options
New WordPress options |
---|
can_compress_scripts |
theysaidso_admin_options |
db_upgraded |
widget_recent-posts |
widget_theysaidso_widget |
widget_recent-comments |
Browser metrics Passed 4 tests
This is an overview of browser requirements for Emergency Alerts
This plugin renders optimally with no browser resource issues detected
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,903 ▲117 | 13.33 ▼1.01 | 10.12 ▲7.95 | 46.63 ▲2.04 |
Dashboard /wp-admin | 2,199 ▲19 | 5.48 ▼0.18 | 83.53 ▼3.92 | 38.25 ▲0.77 |
Posts /wp-admin/edit.php | 2,101 ▲1 | 1.99 ▲0.01 | 34.79 ▼0.94 | 33.94 ▼4.69 |
Add New Post /wp-admin/post-new.php | 1,531 ▼0 | 23.24 ▲0.53 | 628.73 ▼57.46 | 52.16 ▲6.97 |
Media Library /wp-admin/upload.php | 1,395 ▲1 | 4.21 ▲0.03 | 98.78 ▼3.60 | 47.26 ▼0.06 |
Emergency Alert /wp-admin/options-general.php?page=wpm-ea-settings | 1,716 | 6.62 | 134.26 | 63.80 |
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
It is recommended to fix the following
- Zombie WordPress options were found after uninstall: 6 options
- widget_recent-comments
- theysaidso_admin_options
- widget_theysaidso_widget
- can_compress_scripts
- db_upgraded
- widget_recent-posts
Smoke tests 75% from 4 tests
Server-side errors Passed 1 test
🔹 Test weight: 20 | This is a shallow check for server-side errors
Everything seems fine, however this is by no means an exhaustive test
SRP 50% from 2 tests
🔹 Tests weight: 20 | The single-responsibility principle applies for WordPress plugins as well - please make sure your PHP files perform no actions when accessed directly
The following issues need your attention
- 9× GET requests to PHP files have triggered server-side errors or warnings:
- > PHP Fatal error
Uncaught Error: Call to undefined function esc_attr() in wp-content/plugins/emergency-alert/lib/views/alert-footer-fixed.php:3
- > PHP Fatal error
Uncaught Error: Call to undefined function esc_attr() in wp-content/plugins/emergency-alert/lib/views/alert-header-fixed.php:3
- > PHP Fatal error
Uncaught Error: Call to undefined function esc_attr() in wp-content/plugins/emergency-alert/lib/views/alert-lightbox.php:4
- > PHP Fatal error
Uncaught Error: Call to undefined function add_action() in wp-content/plugins/emergency-alert/lib/init.php:39
- > PHP Fatal error
Uncaught Error: Call to undefined function admin_url() in wp-content/plugins/emergency-alert/lib/views/js-hooks.php:3
- > PHP Fatal error
Uncaught Error: Using $this when not in object context in wp-content/plugins/emergency-alert/lib/views/admin-settings.php:5
- > PHP Fatal error
Uncaught Error: Call to undefined function plugin_basename() in wp-content/plugins/emergency-alert/wpm-emergency-alert.php:9
- > PHP Fatal error
Uncaught Error: Call to undefined function esc_attr() in wp-content/plugins/emergency-alert/lib/views/alert-footer-absolute.php:3
- > PHP Fatal error
Uncaught Error: Call to undefined function esc_attr() in wp-content/plugins/emergency-alert/lib/views/alert-header-absolute.php:3
- > PHP Fatal error
User-side errors Passed 1 test
🔹 Test weight: 20 | A shallow check that no browser errors were triggered
There were no browser issues found
Optimizations
Plugin configuration 96% from 29 tests
readme.txt Passed 16 tests
The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
10 plugin tags: closing, alert, covid19, banner, lightbox...
emergency-alert/wpm-emergency-alert.php 92% from 13 tests
The primary PHP file in "Emergency Alerts" version 1.4.0 is used by WordPress to initiate all plugin functionality
It is important to fix the following:
- Main file name: It is recommended to name the main PHP file as the plugin slug ("emergency-alert.php" instead of "wpm-emergency-alert.php")
Code Analysis Passed 3 tests
File types Passed 1 test
🔸 Test weight: 35 | This is an overview of file extensions present in this plugin and a short test that no dangerous files are bundled with this plugin
Good job! No executable or dangerous file extensions detected484 lines of code in 11 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 9 | 62 | 11 | 435 |
JavaScript | 1 | 6 | 0 | 27 |
CSS | 1 | 5 | 4 | 22 |
PHP code Passed 2 tests
An overview 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.32 |
Average class complexity | 42.00 |
▷ Minimum class complexity | 42.00 |
▷ Maximum class complexity | 42.00 |
Average method complexity | 4.15 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 12.00 |
Code structure | ||
---|---|---|
Namespaces | 1 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 1 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 1 | 100.00% |
▷ Final classes | 0 | 0.00% |
Methods | 13 | |
▷ Static methods | 3 | 23.08% |
▷ Public methods | 12 | 92.31% |
▷ Protected methods | 0 | 0.00% |
▷ Private methods | 1 | 7.69% |
Functions | 0 | |
▷ Named functions | 0 | 0.00% |
▷ Anonymous functions | 0 | 0.00% |
Constants | 6 | |
▷ Global constants | 1 | 16.67% |
▷ Class constants | 5 | 83.33% |
▷ Public constants | 5 | 100.00% |
Plugin size Passed 2 tests
Image compression Passed 2 tests
Using a strong compression for your PNG files is a great way to speed-up your plugin
1 PNG file occupies 0.12MB with 0.08MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
screenshot-1.png | 125.45KB | 39.54KB | ▼ 68.48% |