84% permissions-editor-for-ninja-forms

Code Review | Permissions Editor for Ninja Forms

WordPress plugin Permissions Editor for Ninja Forms scored84%from 54 tests.

About plugin

  • Plugin page: permissions-edito...
  • Plugin version: 1.2.1
  • PHP version: 7.4.16
  • WordPress compatibility: 4.1-4.9.1
  • WordPress version: 6.3.1
  • First release: Nov 20, 2017
  • Latest release: Jan 15, 2018
  • Number of updates: 11
  • Update frequency: every 5.3 days
  • Top authors: rapidweb (100%)

Code review

54 tests

User reviews

4 reviews

Install metrics

1,000+ active /13,268 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
This plugin's installer ran successfully

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

An overview of server-side resources used by Permissions Editor for Ninja Forms
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0039.06 ▼7.11
Dashboard /wp-admin3.31 ▲0.0048.22 ▼4.27
Posts /wp-admin/edit.php3.36 ▲0.0048.86 ▲4.81
Add New Post /wp-admin/post-new.php5.89 ▲0.0086.74 ▼12.67
Media Library /wp-admin/upload.php3.23 ▲0.0037.82 ▼3.93

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

Analyzing filesystem and database footprints of this plugin
There were no storage issued detected upon installing this plugin
Filesystem: 6 new files
Database: no new tables, 6 new options
New WordPress options
db_upgraded
widget_theysaidso_widget
theysaidso_admin_options
widget_recent-comments
can_compress_scripts
widget_recent-posts

Browser metrics Passed 4 tests

Permissions Editor for Ninja Forms: an overview of browser usage
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,814 ▲5314.72 ▲0.371.89 ▲0.1741.56 ▼3.50
Dashboard /wp-admin2,192 ▲125.51 ▼0.1387.63 ▼13.9639.08 ▼4.59
Posts /wp-admin/edit.php2,100 ▼31.96 ▼0.0736.08 ▼7.2635.33 ▼3.94
Add New Post /wp-admin/post-new.php1,529 ▲123.18 ▼0.10654.48 ▲34.2353.37 ▲2.35
Media Library /wp-admin/upload.php1,397 ▼34.24 ▲0.06100.24 ▼8.8844.31 ▲0.80

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

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
The following items require your attention
  • Zombie WordPress options were found after uninstall: 6 options
    • theysaidso_admin_options
    • db_upgraded
    • widget_theysaidso_widget
    • widget_recent-posts
    • can_compress_scripts
    • widget_recent-comments

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Even though everything seems fine, this is not 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 take a closer look at the following
  • 2× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/permissions-editor-for-ninja-forms/permissions-editor-for-ninja_forms.php:15
    • > PHP Fatal error
      Uncaught Error: Call to undefined function __() in wp-content/plugins/permissions-editor-for-ninja-forms/penf_role_matrix.php:4

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

Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
These attributes need your attention:
  • Plugin Name: "Plugin Name" should be replaced with the name of your plugin on the first line ( === permissions-editor-for-ninja-forms === )
You can take inspiration from this readme.txt

permissions-editor-for-ninja-forms/permissions-editor-for-ninja_forms.php 92% from 13 tests

Analyzing the main PHP file in "Permissions Editor for Ninja Forms" version 1.2.1
You should first fix the following items:
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("permissions-editor-for-ninja-forms.php" instead of "permissions-editor-for-ninja_forms.php")

Code Analysis Passed 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
There were no executable files found in this plugin178 lines of code in 3 files:
LanguageFilesBlank linesComment linesLines of code
PHP24612175
Markdown1203

PHP code Passed 2 tests

This is a very shot review 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 code0.37
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%
Functions14
▷ Named functions14100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
There are no PNG files in this plugin