84% members-restricted-access

Code Review | Members Restricted Access

WordPress plugin Members Restricted Access scored84%from 54 tests.

About plugin

  • Plugin page: members-restricte...
  • Plugin version: 3.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0.1-4.4.2
  • WordPress version: 6.3.1
  • First release: Mar 1, 2015
  • Latest release: Mar 3, 2016
  • Number of updates: 7
  • Update frequency: every 52.6 days
  • Top authors: mcostales84 (100%)

Code review

54 tests

User reviews

4 reviews

Install metrics

100+ active /5,995 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
Install script ran successfully

Server metrics [RAM: ▼0.00MB] [CPU: ▼5.48ms] Passed 4 tests

This is a short check of server-side resources used by Members Restricted Access
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0145.30 ▲1.42
Dashboard /wp-admin3.31 ▼0.0355.50 ▼17.96
Posts /wp-admin/edit.php3.36 ▲0.0147.68 ▼0.95
Add New Post /wp-admin/post-new.php5.89 ▲0.0192.32 ▼2.33
Media Library /wp-admin/upload.php3.24 ▲0.0133.73 ▼0.67

Server storage [IO: ▲0.00MB] [DB: ▲0.00MB] Passed 3 tests

How much does this plugin use your filesystem and database?
This plugin was installed successfully
Filesystem: 2 new files
Database: no new tables, 6 new options
New WordPress options
theysaidso_admin_options
can_compress_scripts
db_upgraded
widget_theysaidso_widget
widget_recent-posts
widget_recent-comments

Browser metrics Passed 4 tests

A check of browser resources used by Members Restricted Access
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,789 ▲2814.27 ▼0.092.01 ▼0.0346.05 ▲3.14
Dashboard /wp-admin2,189 ▲125.51 ▼0.0284.99 ▼19.2539.45 ▼4.41
Posts /wp-admin/edit.php2,100 ▼31.95 ▼0.0535.94 ▼0.6935.35 ▼1.69
Add New Post /wp-admin/post-new.php1,526 ▼223.36 ▲0.15664.15 ▼29.2354.95 ▼11.65
Media Library /wp-admin/upload.php1,394 ▼64.17 ▲0.0295.99 ▼15.0443.60 ▼3.99

Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 75% from 4 tests

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
It is recommended to fix the following
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • db_upgraded
    • widget_recent-comments
    • theysaidso_admin_options
    • widget_recent-posts
    • widget_theysaidso_widget
    • can_compress_scripts

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Good news, no errors were detected

SRP 50% from 2 tests

🔹 Tests weight: 20 | A shallow check of the single-responsibility principle; PHP files should perform no action - including output of placeholder text - and trigger no errors when accessed directly
The following issues need your attention
  • 1× PHP files perform the action of outputting non-empty strings when accessed directly:
    • > /wp-content/plugins/members-restricted-access/members-restricted-access.php

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 Passed 29 tests

readme.txt Passed 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
4 plugin tags: members, restric by role, restrict access, visitor

members-restricted-access/members-restricted-access.php Passed 13 tests

The main PHP script in "Members Restricted Access" version 3.0 is automatically included on every request by WordPress
117 characters long description:
This plugin creates shortcodes to restrict the access to Visitors, Members or by role. You can use nested shortcodes.

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
Everything looks great! No dangerous files found in this plugin30 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code
PHP191230

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code1.00
Average class complexity0.00
▷ Minimum class complexity0.00
▷ Maximum class complexity0.00
Average method complexity0.00
▷ Minimum method complexity0.00
▷ Maximum method complexity0.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes0
▷ Abstract classes00.00%
▷ Concrete classes00.00%
▷ Final classes00.00%
Methods0
▷ Static methods00.00%
▷ Public methods00.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions3
▷ Named functions3100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
No PNG files were detected