90% manage-user-roles

Code Review | Manage User Roles

WordPress plugin Manage User Roles scored 90% from 54 tests.

About plugin

  • Plugin page: manage-user-roles
  • Plugin version: 1.0.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0-4.4.1
  • WordPress version: 6.3.1
  • First release: Jan 27, 2016
  • Latest release: Feb 18, 2016
  • Number of updates: 6
  • Update frequency: every 4.3 days
  • Top authors: airtonvancin (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 878 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
Install script ran successfully

Server metrics [RAM: ▲0.01MB] [CPU: ▼1.78ms] Passed 4 tests

Analyzing server-side resources used by Manage User Roles
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0136.19 ▼4.79
Dashboard /wp-admin3.32 ▲0.0244.73 ▼0.68
Posts /wp-admin/edit.php3.37 ▲0.0148.01 ▲0.07
Add New Post /wp-admin/post-new.php5.90 ▲0.0183.03 ▼1.73
Media Library /wp-admin/upload.php3.24 ▲0.0138.46 ▲4.86

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

A short overview of filesystem and database impact
The plugin installed successfully
Filesystem: 8 new files
Database: no new tables, 6 new options
New WordPress options
db_upgraded
widget_theysaidso_widget
widget_recent-posts
widget_recent-comments
theysaidso_admin_options
can_compress_scripts

Browser metrics Passed 4 tests

Manage User Roles: an overview of browser usage
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,825 ▲9013.17 ▼1.011.92 ▲0.0841.20 ▲0.68
Dashboard /wp-admin2,200 ▲95.82 ▲0.94105.29 ▲5.8639.15 ▼7.41
Posts /wp-admin/edit.php2,089 ▼31.98 ▼0.0340.15 ▼2.2438.83 ▲1.77
Add New Post /wp-admin/post-new.php1,514 ▼2817.66 ▼0.68662.50 ▲58.9849.39 ▲3.85
Media Library /wp-admin/upload.php1,388 ▼34.30 ▲0.0893.25 ▼10.7440.58 ▼6.78

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

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

Smoke tests Passed 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 Passed 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
No output text or server-side errors detected on direct access of PHP files

User-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

It's important to format your readme.txt file correctly as it is parsed for the public listing of your plugin
4 plugin tags: roles, administration, adm, user

manage-user-roles/manage-user-roles.php 92% from 13 tests

The main PHP script in "Manage User Roles" version 1.0.0 is automatically included on every request by WordPress
Please make the necessary changes and fix the following:
  • Domain Path: The domain path folder does not exist ("/languages")

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
There were no executable files found in this plugin279 lines of code in 6 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript11743176
PHP3185349
Markdown122033
JSON10021

PHP code Passed 2 tests

A short review of cyclomatic complexity and code structure
All good! No complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.54
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%
Functions4
▷ Named functions4100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Often times overlooked, PNG files can occupy unnecessary space in your plugin
PNG images were not found in this plugin