94% simple-membership-menu

Code Review | Simple Membership Menu

WordPress plugin Simple Membership Menu scored 94% from 54 tests.

About plugin

  • Plugin page: simple-membership...
  • Plugin version: 1.0.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.3-4.3
  • WordPress version: 5.8.1
  • First release: Oct 3, 2015
  • Latest release: Oct 3, 2015
  • Number of updates: 6
  • Update frequency: every 0.5 days
  • Top authors: gioindahouz (100%)

Code review

54 tests

User reviews

5 reviews

Install metrics

100+ active / 3,695 total downloads


Plugin footprint Passed 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
This plugin's installer ran successfully

Server metrics [RAM: ▲0.02MB] [CPU: ▼108.21ms] Passed 4 tests

A check of server-side resources used by Simple Membership Menu
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /2.86 ▲0.14211.26 ▲192.49
Dashboard /wp-admin3.08 ▲0.0399.71 ▲59.21
Posts /wp-admin/edit.php3.14 ▲0.03103.01 ▲62.92
Add New Post /wp-admin/post-new.php5.44 ▲0.0196.14 ▼559.87
Media Library /wp-admin/upload.php3.03 ▲0.0333.70 ▲4.89

Server storage [IO: ▲0.03MB] [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: 5 new files
Database: no new tables, no new options

Browser metrics Passed 4 tests

An overview of browser requirements for Simple Membership Menu
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,678 ▲8215.74 ▲0.137.83 ▼0.66335.20 ▲287.96
Dashboard /wp-admin2,967 ▲365.84 ▼0.10181.78 ▲40.01196.08 ▲85.01
Posts /wp-admin/edit.php2,739 ▼02.82 ▲0.1580.60 ▲10.5293.98 ▲1.94
Add New Post /wp-admin/post-new.php1,672 ▼1,96418.91 ▲3.98448.71 ▲6.01124.51 ▲20.35
Media Library /wp-admin/upload.php1,813 ▲34.99 ▼0.01152.97 ▲5.14120.43 ▼12.01

Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] Passed 4 tests

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
This plugin's uninstaller ran successfully

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Good news, no errors were detected

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
Almost there! Just fix the following items
  • 1× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Class 'Walker_Nav_Menu_Edit' not found in wp-content/plugins/simple-membership-menu/swpm-menu-nav-menu-edit.php:8

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
There were no browser issues found


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
Attributes that need to be fixed:
  • Tags: Too many tags (24 tag instead of maximum 10); only the first 5 tags are used in your directory listing
The official readme.txt might help

simple-membership-menu/swpm-menu.php 92% from 13 tests

The main file in "Simple Membership Menu" v. 1.0.0 serves as a complement to information provided in readme.txt and as the entry point to the plugin
You should first fix the following items:
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("simple-membership-menu.php" instead of "swpm-menu.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of programming languages used in this plugin; dangerous file extensions are not allowed
Everything looks great! No dangerous files found in this plugin164 lines of code in 3 files:
LanguageFilesBlank linesComment linesLines of code

PHP code Passed 2 tests

Analyzing cyclomatic complexity and code structure
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.31
Average class complexity9.50
▷ Minimum class complexity1.00
▷ Maximum class complexity18.00
Average method complexity2.55
▷ Minimum method complexity1.00
▷ Maximum method complexity6.00
Code structure
▷ Abstract classes00.00%
▷ Concrete classes2100.00%
▷ Final classes00.00%
▷ Static methods19.09%
▷ Public methods1090.91%
▷ Protected methods19.09%
▷ Private methods00.00%
▷ Named functions1100.00%
▷ Anonymous functions00.00%
▷ Global constants00.00%
▷ Class constants2100.00%
▷ Public constants2100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

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