Benchmarks
Plugin footprint 83% from 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | Checking the installer triggered no errors
Installer ran successfully
Server metrics [RAM: ▲0.04MB] [CPU: ▼6.97ms] Passed 4 tests
A check of server-side resources used by WP Allowed Hosts
Normal server usage
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.49 ▲0.03 | 37.52 ▼11.08 |
Dashboard /wp-admin | 3.34 ▲0.04 | 44.06 ▼8.33 |
Posts /wp-admin/edit.php | 3.39 ▲0.04 | 45.63 ▼1.32 |
Add New Post /wp-admin/post-new.php | 5.92 ▲0.04 | 92.27 ▼7.16 |
Media Library /wp-admin/upload.php | 3.27 ▲0.04 | 34.15 ▼0.79 |
Allowed Hosts /wp-admin/options-general.php?page=ah-settings-page | 3.23 | 29.77 |
Server storage [IO: ▲0.01MB] [DB: ▲0.00MB] Passed 3 tests
Analyzing filesystem and database footprints of this plugin
The plugin installed successfully
Filesystem: 4 new files
Database: no new tables, 8 new options
New WordPress options |
---|
allowed-hosts |
widget_recent-posts |
widget_recent-comments |
theysaidso_admin_options |
widget_theysaidso_widget |
db_upgraded |
can_compress_scripts |
allowed-hosts-regex |
Browser metrics Passed 4 tests
A check of browser resources used by WP Allowed Hosts
Minimal impact on browser resources
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,804 ▲33 | 13.28 ▼1.37 | 1.99 ▲0.22 | 43.31 ▲5.29 |
Dashboard /wp-admin | 2,210 ▲19 | 5.88 ▲1.00 | 98.00 ▼17.76 | 40.51 ▼3.24 |
Posts /wp-admin/edit.php | 2,096 ▲7 | 2.05 ▲0.06 | 37.11 ▼0.09 | 31.69 ▼3.34 |
Add New Post /wp-admin/post-new.php | 1,517 ▼25 | 17.72 ▼0.65 | 610.77 ▼42.77 | 46.20 ▼17.14 |
Media Library /wp-admin/upload.php | 1,395 ▲7 | 4.14 ▼0.10 | 95.65 ▼9.52 | 41.10 ▼4.17 |
Allowed Hosts /wp-admin/options-general.php?page=ah-settings-page | 799 | 2.05 | 23.51 | 26.71 |
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
Please fix the following items
- Zombie WordPress options detected upon uninstall: 6 options
- theysaidso_admin_options
- db_upgraded
- widget_recent-posts
- can_compress_scripts
- widget_recent-comments
- widget_theysaidso_widget
Smoke tests 75% from 4 tests
Server-side errors Passed 1 test
🔹 Test weight: 20 | A smoke test targeting server-side errors
The smoke test was a success, however most plugin functionality was not tested
SRP 50% from 2 tests
🔹 Tests weight: 20 | The single-responsibility principle: PHP files have to remain inert when accessed directly, throwing no errors and performing no actions
The following issues need your attention
- 3× PHP files trigger server errors when accessed directly:
- > PHP Warning
Use of undefined constant ABSPATH - assumed 'ABSPATH' (this will throw an Error in a future version of PHP) in wp-content/plugins/wp-allow-hosts/allowed-hosts.php on line 18
- > PHP Warning
require_once(ABSPATH/wp-admin/includes/plugin.php): failed to open stream: No such file or directory in wp-content/plugins/wp-allow-hosts/allowed-hosts.php on line 18
- > PHP Fatal error
require_once(): Failed opening required 'ABSPATH/wp-admin/includes/plugin.php' (include_path='.:/usr/share/php') in wp-content/plugins/wp-allow-hosts/allowed-hosts.php on line 18
- > PHP Warning
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 96% 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
5 plugin tags: allow, multisite, filter, hosts, host
wp-allow-hosts/allowed-hosts.php 92% from 13 tests
This is the main PHP file of "WP Allowed Hosts" version 1.0.8, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
The following require your attention:
- Main file name: Please rename the main PHP file in this plugin to the plugin slug ("wp-allow-hosts.php" instead of "allowed-hosts.php")
Code Analysis Passed 3 tests
File types Passed 1 test
🔸 Test weight: 35 | A short check of programming languages and file extensions; no executable files are allowed
Success! There were no dangerous files found in this plugin165 lines of code in 2 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 1 | 23 | 14 | 162 |
Markdown | 1 | 1 | 0 | 3 |
PHP code Passed 2 tests
A brief analysis of cyclomatic complexity and code structure for this plugin
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.53 |
Average class complexity | 17.00 |
▷ Minimum class complexity | 16.00 |
▷ Maximum class complexity | 18.00 |
Average method complexity | 5.14 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 11.00 |
Code structure | ||
---|---|---|
Namespaces | 0 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 2 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 2 | 100.00% |
▷ Final classes | 0 | 0.00% |
Methods | 8 | |
▷ Static methods | 0 | 0.00% |
▷ Public methods | 8 | 100.00% |
▷ Protected methods | 0 | 0.00% |
▷ Private methods | 0 | 0.00% |
Functions | 1 | |
▷ Named functions | 0 | 0.00% |
▷ Anonymous functions | 1 | 100.00% |
Constants | 0 | |
▷ Global constants | 0 | 0.00% |
▷ Class constants | 0 | 0.00% |
▷ Public constants | 0 | 0.00% |
Plugin size Passed 2 tests
Image compression Passed 2 tests
It is recommended to compress PNG files in your plugin to minimize bandwidth usage
There are no PNG files in this plugin