Benchmarks
Plugin footprint 83% from 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | The install procedure must perform silently
Install script ran successfully
Server metrics [RAM: ▲0.05MB] [CPU: ▼4.51ms] Passed 4 tests
Server-side resources used by Simple Restrict
This plugin has minimal impact on server resources
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.51 ▲0.05 | 38.05 ▼5.33 |
Dashboard /wp-admin | 3.35 ▲0.05 | 44.55 ▼1.59 |
Posts /wp-admin/edit.php | 3.40 ▲0.05 | 47.58 ▲0.32 |
Add New Post /wp-admin/post-new.php | 5.99 ▲0.10 | 87.53 ▼10.23 |
Media Library /wp-admin/upload.php | 3.27 ▲0.05 | 32.60 ▼0.88 |
Permissions /wp-admin/edit-tags.php?taxonomy=simple-restrict-permission&post_type=page | 3.27 | 32.44 |
Simple Restrict /wp-admin/options-general.php?page=simple_restrict_plugin | 3.30 | 36.13 |
Server storage [IO: ▲0.07MB] [DB: ▲0.00MB] Passed 3 tests
A short overview of filesystem and database impact
There were no storage issued detected upon installing this plugin
Filesystem: 22 new files
Database: no new tables, 6 new options
New WordPress options |
---|
can_compress_scripts |
widget_theysaidso_widget |
db_upgraded |
widget_recent-posts |
widget_recent-comments |
theysaidso_admin_options |
Browser metrics Passed 4 tests
This is an overview of browser requirements for Simple Restrict
Minimal impact on browser resources
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,895 ▲138 | 13.62 ▼0.60 | 4.86 ▲2.92 | 41.31 ▼1.23 |
Dashboard /wp-admin | 2,218 ▲30 | 4.86 ▼0.25 | 107.22 ▼7.20 | 37.92 ▼9.39 |
Posts /wp-admin/edit.php | 2,101 ▲12 | 2.01 ▲0.02 | 38.92 ▼0.27 | 34.66 ▼1.64 |
Add New Post /wp-admin/post-new.php | 1,524 ▼9 | 17.64 ▼5.57 | 682.65 ▲27.78 | 60.52 ▲1.94 |
Media Library /wp-admin/upload.php | 1,400 ▲15 | 4.21 ▼0.10 | 94.58 ▼5.85 | 42.92 ▼1.58 |
Permissions /wp-admin/edit-tags.php?taxonomy=simple-restrict-permission&post_type=page | 1,271 | 2.14 | 27.38 | 27.29 |
Simple Restrict /wp-admin/options-general.php?page=simple_restrict_plugin | 1,447 | 6.44 | 117.20 | 59.26 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 75% from 4 tests
🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
You still need to fix the following
- This plugin does not fully uninstall, leaving 6 options in the database
- db_upgraded
- widget_recent-posts
- can_compress_scripts
- widget_theysaidso_widget
- theysaidso_admin_options
- widget_recent-comments
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: PHP files have to remain inert when accessed directly, throwing no errors and performing no actions
Please fix the following
- 2× GET requests to PHP files return non-empty strings:
- > /wp-content/plugins/simple-restrict/admin/partials/simple-restrict-admin-display.php
- > /wp-content/plugins/simple-restrict/public/partials/simple-restrict-public-display.php
User-side errors Passed 1 test
🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
There were no browser issues found
Optimizations
Plugin configuration 97% from 29 tests
readme.txt 94% from 16 tests
The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
Please fix the following attributes:
- Tags: Too many tags (12 tag instead of maximum 10); only the first 5 tags are used in your directory listing
simple-restrict/simple-restrict.php Passed 13 tests
This is the main PHP file of "Simple Restrict" version 1.2.5, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
83 characters long description:
Restrict pages based on permissions assigned to pages and granted in user profiles.
Code Analysis Passed 3 tests
File types Passed 1 test
🔸 Test weight: 35 | A short review of files and their extensions; it is not recommended to include executable files
There were no executable files found in this plugin463 lines of code in 16 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 12 | 178 | 622 | 442 |
CSS | 2 | 2 | 8 | 15 |
JavaScript | 2 | 4 | 54 | 6 |
PHP code Passed 2 tests
Cyclomatic complexity and code structure are the fingerprint of this plugin
This plugin has no cyclomatic complexity problems
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.18 |
Average class complexity | 5.29 |
▷ Minimum class complexity | 1.00 |
▷ Maximum class complexity | 17.00 |
Average method complexity | 1.70 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 11.00 |
Code structure | ||
---|---|---|
Namespaces | 0 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 7 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 7 | 100.00% |
▷ Final classes | 0 | 0.00% |
Methods | 43 | |
▷ Static methods | 2 | 4.65% |
▷ Public methods | 38 | 88.37% |
▷ Protected methods | 0 | 0.00% |
▷ Private methods | 5 | 11.63% |
Functions | 3 | |
▷ Named functions | 3 | 100.00% |
▷ Anonymous functions | 0 | 0.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
Often times overlooked, PNG files can occupy unnecessary space in your plugin
No PNG files were detected