Benchmarks
Plugin footprint 40% from 16 tests
Installer 0% from 1 test
🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
The following installer errors require your attention
- The plugin did not install without errors
- > Warning in wp-content/plugins/allowed-routes/allowedroutes.php+28
Use of undefined constant ALWDRTS_DISABLE_ROUTING - assumed 'ALWDRTS_DISABLE_ROUTING' (this will throw an Error in a future version of PHP)
Server metrics [RAM: ▼1.90MB] [CPU: ▼52.58ms] Passed 4 tests
Server-side resources used by Allowed Routes
Server-side resource usage in normal parameters
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 2.09 ▼1.37 | 4.82 ▼33.59 |
Dashboard /wp-admin | 2.11 ▼1.19 | 6.32 ▼43.63 |
Posts /wp-admin/edit.php | 2.11 ▼1.24 | 6.78 ▼43.74 |
Add New Post /wp-admin/post-new.php | 2.11 ▼3.78 | 5.98 ▼89.36 |
Media Library /wp-admin/upload.php | 2.11 ▼1.12 | 5.60 ▼29.10 |
Server storage [IO: ▲0.43MB] [DB: ▲0.00MB] Passed 3 tests
Filesystem and database footprint
There were no storage issued detected upon installing this plugin
Filesystem: 12 new files
Database: no new tables, 6 new options
New WordPress options |
---|
theysaidso_admin_options |
db_upgraded |
can_compress_scripts |
widget_recent-posts |
widget_theysaidso_widget |
widget_recent-comments |
Browser metrics Passed 4 tests
This is an overview of browser requirements for Allowed Routes
This plugin renders optimally with no browser resource issues detected
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,822 ▲51 | 13.24 ▼1.15 | 4.23 ▲2.25 | 43.42 ▲0.49 |
Dashboard /wp-admin | 2,231 ▲45 | 4.84 ▼1.04 | 107.63 ▼17.17 | 39.66 ▼7.10 |
Posts /wp-admin/edit.php | 2,111 ▲22 | 2.02 ▲0.02 | 33.70 ▼6.95 | 33.35 ▼7.11 |
Add New Post /wp-admin/post-new.php | 1,533 ▲2 | 23.23 ▲0.24 | 663.30 ▲11.64 | 68.46 ▲15.09 |
Media Library /wp-admin/upload.php | 1,410 ▲25 | 4.21 ▲0.02 | 94.83 ▼10.14 | 43.39 ▼4.03 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 50% from 4 tests
🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
These items require your attention
- Uninstall procedure validation failed for this plugin
- > Warning in wp-content/plugins/allowed-routes/allowedroutes.php+28
Use of undefined constant ALWDRTS_DISABLE_ROUTING - assumed 'ALWDRTS_DISABLE_ROUTING' (this will throw an Error in a future version of PHP)
- The uninstall procedure has failed, leaving 7 options in the database
- enabled
- widget_theysaidso_widget
- theysaidso_admin_options
- can_compress_scripts
- widget_recent-posts
- db_upgraded
- widget_recent-comments
Smoke tests 50% 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 0% 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
Please fix the following items
- 1× GET requests to PHP files return non-empty strings:
- > /wp-content/plugins/allowed-routes/allowedroutes.php
- 5× PHP files trigger server-side errors or warnings when accessed directly:
- > PHP Fatal error
Uncaught Error: Using $this when not in object context in wp-content/plugins/allowed-routes/partials/part_tab1content.php:5
- > PHP Fatal error
Uncaught Error: Class 'AlwdRts_AbstractFunctions' not found in wp-content/plugins/allowed-routes/classes/class.router.php:5
- > PHP Fatal error
Uncaught Error: Using $this when not in object context in wp-content/plugins/allowed-routes/partials/part_tab2sidebar.php:43
- > PHP Fatal error
Uncaught Error: Call to undefined function get_site_url() in wp-content/plugins/allowed-routes/partials/part_tab2content.php:19
- > PHP Fatal error
Uncaught Error: Using $this when not in object context in wp-content/plugins/allowed-routes/partials/part_tab1sidebar.php:47
- > PHP Fatal error
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
Often overlooked, readme.txt is one of the most important files in your plugin
6 plugin tags: whitelist, route, routes, permalink, routing...
allowed-routes/allowedroutes.php 92% from 13 tests
The main PHP script in "Allowed Routes" version 1.1 is automatically included on every request by WordPress
The following require your attention:
- Main file name: Name the main plugin file the same as the plugin slug ("allowed-routes.php" instead of "allowedroutes.php")
Code Analysis Passed 3 tests
File types Passed 1 test
🔸 Test weight: 35 | Executable files are considered dangerous and should not be included with any WordPress plugin
Good job! No executable or dangerous file extensions detected859 lines of code in 10 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 7 | 95 | 304 | 646 |
JavaScript | 1 | 32 | 1 | 133 |
CSS | 2 | 22 | 4 | 80 |
PHP code Passed 2 tests
A brief analysis of cyclomatic complexity and code structure for this plugin
This plugin has no cyclomatic complexity issues
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.40 |
Average class complexity | 24.67 |
▷ Minimum class complexity | 18.00 |
▷ Maximum class complexity | 36.00 |
Average method complexity | 3.29 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 33.00 |
Code structure | ||
---|---|---|
Namespaces | 0 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 3 | |
▷ Abstract classes | 1 | 33.33% |
▷ Concrete classes | 2 | 66.67% |
▷ Final classes | 1 | 50.00% |
Methods | 31 | |
▷ Static methods | 0 | 0.00% |
▷ Public methods | 18 | 58.06% |
▷ Protected methods | 13 | 41.94% |
▷ Private methods | 0 | 0.00% |
Functions | 0 | |
▷ Named functions | 0 | 0.00% |
▷ Anonymous functions | 0 | 0.00% |
Constants | 1 | |
▷ Global constants | 1 | 100.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
No PNG files were detected