Benchmarks
Plugin footprint 65% from 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | Checking the installer triggered no errors
The plugin installed gracefully, with no errors
Server metrics [RAM: ▲5.68MB] [CPU: ▲27.71ms] 75% from 4 tests
An overview of server-side resources used by Restrict User Access - Membership & Content Protection
Please take the time to fix the following items
- Extra RAM: The extra memory usage must be under 5MB (currently 5.68MB on /wp-admin/admin.php?page=freemius)
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 9.20 ▲5.74 | 71.91 ▲35.86 |
Dashboard /wp-admin | 9.22 ▲5.87 | 78.81 ▲19.14 |
Posts /wp-admin/edit.php | 9.22 ▲5.86 | 86.60 ▲36.85 |
Add New Post /wp-admin/post-new.php | 11.12 ▲5.23 | 119.64 ▲18.99 |
Media Library /wp-admin/upload.php | 9.22 ▲5.99 | 71.31 ▲36.92 |
Freemius Debug [v.2.5.10] /wp-admin/admin.php?page=freemius | 9.22 | 67.32 |
Server storage [IO: ▲3.61MB] [DB: ▲0.00MB] Passed 3 tests
Input-output and database impact of this plugin
No storage issues were detected
Filesystem: 277 new files
Database: no new tables, 11 new options
New WordPress options |
---|
can_compress_scripts |
_ca_condition_type_cache |
theysaidso_admin_options |
fs_active_plugins |
fs_accounts |
db_upgraded |
rua_plugin_version |
fs_debug_mode |
widget_recent-comments |
widget_theysaidso_widget |
... |
Browser metrics Passed 4 tests
A check of browser resources used by Restrict User Access - Membership & Content Protection
This plugin renders optimally with no browser resource issues detected
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,873 ▲127 | 14.52 ▼0.08 | 1.76 ▲0.04 | 29.44 ▼13.88 |
Dashboard /wp-admin | 2,254 ▲63 | 5.86 ▼0.04 | 105.54 ▲4.64 | 40.29 ▼5.77 |
Posts /wp-admin/edit.php | 2,143 ▲54 | 2.01 ▼0.04 | 40.82 ▼1.16 | 38.77 ▼1.96 |
Add New Post /wp-admin/post-new.php | 1,533 ▲4 | 22.94 ▼0.43 | 687.45 ▲30.23 | 51.41 ▼7.38 |
Media Library /wp-admin/upload.php | 1,435 ▲50 | 4.20 ▲0.02 | 95.40 ▼4.91 | 46.66 ▲2.89 |
Freemius Debug [v.2.5.10] /wp-admin/admin.php?page=freemius | 1,098 | 1.85 | 24.86 | 27.45 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 50% from 4 tests
🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
Please fix the following items
- The plugin did not uninstall gracefully
- > Notice in wp-content/plugins/restrict-user-access/lib/freemius/includes/class-freemius.php+8486
Undefined property: stdClass::$plugins
- This plugin did not uninstall successfully, leaving 11 options in the database
- widget_theysaidso_widget
- rua_plugin_version
- widget_recent-comments
- theysaidso_admin_options
- can_compress_scripts
- _ca_condition_type_cache
- fs_debug_mode
- fs_active_plugins
- db_upgraded
- widget_recent-posts
- ...
Smoke tests 75% from 4 tests
Server-side errors Passed 1 test
🔹 Test weight: 20 | A smoke test targeting server-side errors
Even though no errors were found, this is by no means an exhaustive test
SRP 50% from 2 tests
🔹 Tests weight: 20 | It is important to ensure that your PHP files perform no action when accessed directly, respecting the single-responsibility principle
The following issues need your attention
- 23× GET requests to PHP files have triggered server-side errors or warnings (only 10 are shown):
- > PHP Fatal error
Uncaught Error: Call to undefined function _e() in wp-content/plugins/restrict-user-access/lib/wp-content-aware-engine/view/condition_options.php:10
- > PHP Fatal error
Uncaught Error: Interface 'RUA_Level_Interface' not found in wp-content/plugins/restrict-user-access/models/level.php:9
- > PHP Fatal error
Uncaught Error: Class 'RUA_Role_Member_Automator' not found in wp-content/plugins/restrict-user-access/automators/user_role_sync.php:9
- > PHP Fatal error
Uncaught Error: Class 'RUA_Member_Automator' not found in wp-content/plugins/restrict-user-access/automators/user_role.php:9
- > PHP Fatal error
Uncaught Error: Class 'RUA_App' not found in wp-content/plugins/restrict-user-access/view/meta_box_member_triggers.php:9
- > PHP Notice
Trying to get property 'post_status' of non-object in wp-content/plugins/restrict-user-access/view/meta_box_publish.php on line 14
- > PHP Fatal error
Uncaught Error: Call to undefined function __() in wp-content/plugins/restrict-user-access/lib/wp-content-aware-engine/view/meta_box.php:10
- > PHP Fatal error
Uncaught Error: Class 'RUA_Member_Automator' not found in wp-content/plugins/restrict-user-access/automators/edd_product.php:9
- > PHP Fatal error
Uncaught Error: Class 'RUA_Members_List' not found in wp-content/plugins/restrict-user-access/view/meta_box_members.php:9
- > PHP Notice
Undefined variable: post in wp-content/plugins/restrict-user-access/view/meta_box_publish.php on line 14
- > PHP Fatal error
User-side errors Passed 1 test
🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
No browser issues were found
Optimizations
Plugin configuration 93% from 29 tests
readme.txt 94% from 16 tests
The readme.txt file is an important file in your plugin as it is parsed by WordPress.org to prepare the public listing of your plugin
Attributes that need to be fixed:
- Donate link: Invalid URI found ("#")
restrict-user-access/restrict-user-access.php 92% from 13 tests
"Restrict User Access - Membership & Content Protection" version 2.4.3's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
Please make the necessary changes and fix the following:
- Domain Path: The domain path points to a folder that does not exist ("/lang/")
Code Analysis 97% from 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
Success! There were no dangerous files found in this plugin40,738 lines of code in 212 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 186 | 9,313 | 20,898 | 40,305 |
Markdown | 2 | 68 | 0 | 216 |
JavaScript | 9 | 34 | 87 | 202 |
CSS | 15 | 0 | 10 | 15 |
PHP code 50% from 2 tests
An short overview of logical lines of code, cyclomatic complexity, and other code metrics
Please fix the following
- Cyclomatic complexity of classes should be reduced to less than 1000 (currently 3,073)
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.59 |
Average class complexity | 55.78 |
▷ Minimum class complexity | 1.00 |
▷ Maximum class complexity | 3,073.00 |
Average method complexity | 4.16 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 94.00 |
Code structure | ||
---|---|---|
Namespaces | 0 | |
Interfaces | 3 | |
Traits | 0 | |
Classes | 95 | |
▷ Abstract classes | 5 | 5.26% |
▷ Concrete classes | 90 | 94.74% |
▷ Final classes | 10 | 11.11% |
Methods | 1,760 | |
▷ Static methods | 233 | 13.24% |
▷ Public methods | 1,279 | 72.67% |
▷ Protected methods | 84 | 4.77% |
▷ Private methods | 397 | 22.56% |
Functions | 129 | |
▷ Named functions | 115 | 89.15% |
▷ Anonymous functions | 14 | 10.85% |
Constants | 184 | |
▷ Global constants | 101 | 54.89% |
▷ Class constants | 83 | 45.11% |
▷ Public constants | 83 | 100.00% |
Plugin size Passed 2 tests
Image compression Passed 2 tests
All PNG images should be compressed to minimize bandwidth usage for end users
3 PNG files occupy 0.04MB with 0.02MB in potential savings
Potential savings
Compression of 3 random PNG files using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
lib/freemius/assets/img/theme-icon.png | 10.97KB | 5.78KB | ▼ 47.37% |
assets/img/icon.png | 18.28KB | 9.41KB | ▼ 48.49% |
lib/freemius/assets/img/plugin-icon.png | 9.16KB | 5.26KB | ▼ 42.58% |