10% easy-and-simple-membership

Code Review | Membership 7

WordPress plugin Membership 7 scored10%from 54 tests.

About plugin

  • Plugin page: easy-and-simple-m...
  • Plugin version: 1.4
  • PHP compatiblity: 7.3+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.8-5.7.2
  • WordPress version: 6.3.1
  • First release: Jun 15, 2021
  • Latest release: Aug 5, 2021
  • Number of updates: 18
  • Update frequency: every 3.9 days
  • Top authors: kunimi (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /636 total downloads

Benchmarks

Plugin footprint 58% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
These installer errors require your attention
  • Install procedure had errors
    • > Deprecated in wp-includes/class-wp-hook.php+310
    Non-static method Membership7::myplugin_activate() should not be called statically

Server metrics [RAM: ▲0.08MB] [CPU: ▼0.14ms] Passed 4 tests

Server-side resources used by Membership 7
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.55 ▲0.0840.86 ▼1.56
Dashboard /wp-admin3.39 ▲0.0850.94 ▼0.48
Posts /wp-admin/edit.php3.51 ▲0.1549.97 ▲3.04
Add New Post /wp-admin/post-new.php5.98 ▲0.0888.01 ▼1.58
Media Library /wp-admin/upload.php3.32 ▲0.0841.18 ▲5.68
Settings /wp-admin/admin.php?page=membership-7-config3.2629.72
Membership Site /wp-admin/admin.php?page=membership-73.2836.34

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

Analyzing filesystem and database footprints of this plugin
This plugin was installed successfully
Filesystem: 6 new files
Database: no new tables, 9 new options
New WordPress options
membership-7_redirect_url_after_sign_up
widget_recent-posts
db_upgraded
theysaidso_admin_options
widget_theysaidso_widget
widget_recent-comments
membership-7_view_authority_no_when_url
can_compress_scripts
membership-7_notify_after_sign_up

Browser metrics Passed 4 tests

A check of browser resources used by Membership 7
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,816 ▲3014.41 ▲0.061.63 ▼0.5944.64 ▼6.06
Dashboard /wp-admin2,222 ▲485.53 ▲0.0190.35 ▼15.5941.36 ▼3.94
Posts /wp-admin/edit.php2,158 ▲581.96 ▼0.0134.14 ▲0.2433.90 ▼5.05
Add New Post /wp-admin/post-new.php6,257 ▲4,73125.88 ▲2.72929.14 ▲249.0763.76 ▲10.01
Media Library /wp-admin/upload.php1,424 ▲244.09 ▼0.10102.55 ▼6.7746.73 ▲2.89
Settings /wp-admin/admin.php?page=membership-7-config8702.0325.7627.87
Membership Site /wp-admin/admin.php?page=membership-78271.9922.6928.67

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
Please fix the following items
  • This plugin did not uninstall successfully, leaving 9 options in the database
    • membership-7_view_authority_no_when_url
    • membership-7_notify_after_sign_up
    • membership-7_redirect_url_after_sign_up
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • can_compress_scripts
    • widget_recent-comments
    • db_upgraded
    • widget_recent-posts

Smoke tests 50% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
These errors were triggered by the plugin
    • > GET request to /wp-admin/admin.php?page=membership-7-config
    • > Notice in wp-content/plugins/easy-and-simple-membership/membership-7.php+119
    Undefined index: posted

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
Please fix the following items
  • 2× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function wp_nonce_field() in wp-content/plugins/easy-and-simple-membership/signup-form.php:15
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/easy-and-simple-membership/membership-7.php:16

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)
No browser issues were found

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file is undoubtedly the most important file in your plugin, preparing it for public listing on WordPress.org
Please fix the following attributes: The official readme.txt might help

easy-and-simple-membership/membership-7.php 85% from 13 tests

The primary PHP file in "Membership 7" version 1.4 is used by WordPress to initiate all plugin functionality
Please make the necessary changes and fix the following:
  • Main file name: Name the main plugin file the same as the plugin slug ("easy-and-simple-membership.php" instead of "membership-7.php")
  • Text Domain: You no longer need to specify the text domain since WordPress 4.6; it must be the same as the plugin slug

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are considered dangerous and should not be included with any WordPress plugin
Everything looks great! No dangerous files found in this plugin429 lines of code in 3 files:
LanguageFilesBlank linesComment linesLines of code
PHP25247328
PO File13234101

PHP code Passed 2 tests

This is a very shot review of cyclomatic complexity and code structure
This plugin has no cyclomatic complexity problems
Cyclomatic complexity
Average complexity per logical line of code0.31
Average class complexity30.00
▷ Minimum class complexity30.00
▷ Maximum class complexity30.00
Average method complexity3.64
▷ Minimum method complexity1.00
▷ Maximum method complexity11.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods11
▷ Static methods19.09%
▷ Public methods11100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions11
▷ Named functions763.64%
▷ Anonymous functions436.36%
Constants7
▷ Global constants00.00%
▷ Class constants7100.00%
▷ Public constants7100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

It is recommended to compress PNG files in your plugin to minimize bandwidth usage
There are no PNG files in this plugin