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.23MB] [CPU: ▼1.62ms] Passed 4 tests
An overview of server-side resources used by REST API Toolbox
This plugin does not affect your website's performance
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.65 ▲0.18 | 35.61 ▼6.47 |
Dashboard /wp-admin | 3.59 ▲0.29 | 48.41 ▲1.02 |
Posts /wp-admin/edit.php | 3.64 ▲0.28 | 47.11 ▼2.61 |
Add New Post /wp-admin/post-new.php | 6.11 ▲0.22 | 89.20 ▲2.78 |
Media Library /wp-admin/upload.php | 3.45 ▲0.22 | 37.74 ▲1.57 |
REST API Toolbox /wp-admin/options-general.php?page=rest-api-toolbox-settings | 3.42 | 31.95 |
Server storage [IO: ▲0.06MB] [DB: ▲0.07MB] Passed 3 tests
Filesystem and database footprint
The plugin installed successfully
Filesystem: 22 new files
Database: no new tables, 6 new options
New WordPress options |
---|
widget_theysaidso_widget |
db_upgraded |
can_compress_scripts |
widget_recent-posts |
theysaidso_admin_options |
widget_recent-comments |
Browser metrics Passed 4 tests
An overview of browser requirements for REST API Toolbox
Minimal impact on browser resources
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,830 ▲69 | 14.37 ▲0.11 | 1.87 ▼0.04 | 41.50 ▼1.83 |
Dashboard /wp-admin | 2,202 ▲28 | 5.59 ▲0.02 | 84.20 ▼23.07 | 41.77 ▼6.04 |
Posts /wp-admin/edit.php | 2,104 ▲7 | 1.98 ▼0.00 | 35.15 ▼2.30 | 31.60 ▼7.50 |
Add New Post /wp-admin/post-new.php | 1,543 ▲15 | 18.19 ▼4.53 | 605.14 ▼16.83 | 81.13 ▲30.17 |
Media Library /wp-admin/upload.php | 1,401 ▼2 | 4.17 ▲0.02 | 97.14 ▼4.42 | 41.39 ▼0.12 |
REST API Toolbox /wp-admin/options-general.php?page=rest-api-toolbox-settings | 822 | 2.00 | 23.85 | 28.29 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.07MB] 75% from 4 tests
🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
The following items require your attention
- This plugin does not fully uninstall, leaving 6 options in the database
- db_upgraded
- can_compress_scripts
- widget_recent-posts
- widget_recent-comments
- widget_theysaidso_widget
- theysaidso_admin_options
Smoke tests 50% from 4 tests
Server-side errors Passed 1 test
🔹 Test weight: 20 | A smoke test targeting server-side errors
Even though everything seems fine, this is not an exhaustive test
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
Almost there! Just fix the following items
- 15× PHP files output non-empty strings when accessed directly via GET requests (only 10 are shown):
- > /wp-content/plugins/rest-api-toolbox/includes/settings/class-rest-api-toolbox-settings-general.php
- > /wp-content/plugins/rest-api-toolbox/admin/partials/admin-help.php
- > /wp-content/plugins/rest-api-toolbox/includes/class-rest-api-toolbox-settings.php
- > /wp-content/plugins/rest-api-toolbox/includes/settings/class-rest-api-toolbox-settings-help.php
- > /wp-content/plugins/rest-api-toolbox/includes/class-rest-api-toolbox-prefix.php
- > /wp-content/plugins/rest-api-toolbox/includes/class-rest-api-toolbox-admin.php
- > /wp-content/plugins/rest-api-toolbox/includes/class-rest-api-toolbox-base.php
- > /wp-content/plugins/rest-api-toolbox/includes/settings/class-rest-api-toolbox-settings-core.php
- > /wp-content/plugins/rest-api-toolbox/includes/settings/class-rest-api-toolbox-settings.php
- > /wp-content/plugins/rest-api-toolbox/includes/settings/class-rest-api-toolbox-settings-ssl.php
- 7× PHP files trigger server errors when accessed directly:
- > PHP Warning
require_once(REST_API_TOOLBOX_ROOTincludes/wp-cli/class-rest-api-toolbox-base-command.php): failed to open stream: No such file or directory in wp-content/plugins/rest-api-toolbox/includes/wp-cli/setup.php on line 11
- > PHP Warning
Use of undefined constant REST_API_TOOLBOX_ROOT - assumed 'REST_API_TOOLBOX_ROOT' (this will throw an Error in a future version of PHP) in wp-content/plugins/rest-api-toolbox/includes/wp-cli/setup.php on line 11
- > PHP Fatal error
Uncaught Error: Class 'REST_API_Toolbox_Base_Command' not found in wp-content/plugins/rest-api-toolbox/includes/wp-cli/class-rest-api-toolbox-rest-api-command.php:5
- > PHP Fatal error
Uncaught Error: Class 'WP_CLI_Command' not found in wp-content/plugins/rest-api-toolbox/includes/wp-cli/class-rest-api-toolbox-base-command.php:3
- > PHP Fatal error
Uncaught Error: Call to undefined function trailingslashit() in wp-content/plugins/rest-api-toolbox/rest-api-toolbox.php:19
- > PHP Fatal error
require_once(): Failed opening required 'REST_API_TOOLBOX_ROOTincludes/wp-cli/class-rest-api-toolbox-base-command.php' (include_path='.:/usr/share/php') in wp-content/plugins/rest-api-toolbox/includes/wp-cli/setup.php on line 11
- > PHP Fatal error
Uncaught Error: Class 'REST_API_Toolbox_Base_Command' not found in wp-content/plugins/rest-api-toolbox/includes/wp-cli/class-rest-api-toolbox-ssl-command.php:5
- > PHP Warning
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 Passed 29 tests
readme.txt Passed 16 tests
The readme.txt file uses markdown syntax to describe your plugin to the world
4 plugin tags: json api, rest api, wp rest api, rest
rest-api-toolbox/rest-api-toolbox.php Passed 13 tests
This is the main PHP file of "REST API Toolbox" version 1.4.3, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
47 characters long description:
Allows easy tweaks of several REST API settings
Code Analysis Passed 3 tests
File types Passed 1 test
🔸 Test weight: 35 | An overview of files in this plugin; executable files are not allowed
Good job! No executable or dangerous file extensions detected1,195 lines of code in 20 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 20 | 484 | 225 | 1,195 |
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.33 |
Average class complexity | 7.59 |
▷ Minimum class complexity | 1.00 |
▷ Maximum class complexity | 44.00 |
Average method complexity | 2.06 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 12.00 |
Code structure | ||
---|---|---|
Namespaces | 0 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 17 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 17 | 100.00% |
▷ Final classes | 0 | 0.00% |
Methods | 106 | |
▷ Static methods | 69 | 65.09% |
▷ Public methods | 98 | 92.45% |
▷ Protected methods | 0 | 0.00% |
▷ Private methods | 8 | 7.55% |
Functions | 0 | |
▷ Named functions | 0 | 0.00% |
▷ Anonymous functions | 0 | 0.00% |
Constants | 3 | |
▷ Global constants | 3 | 100.00% |
▷ Class constants | 0 | 0.00% |
▷ Public constants | 0 | 0.00% |
Plugin size Passed 2 tests
Image compression Passed 2 tests
PNG files should be compressed to save space and minimize bandwidth usage
PNG images were not found in this plugin