83% st-members-list

Code Review | ST Members List

WordPress plugin ST Members List scored83%from 54 tests.

About plugin

  • Plugin page: st-members-list
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0.1-3.4
  • WordPress version: 6.3.1
  • First release: Dec 27, 2015
  • Latest release: Dec 27, 2015
  • Number of updates: 5
  • Update frequency: every 1.4 days
  • Top authors: sujon3g (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /624 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
The plugin installed gracefully, with no errors

Server metrics [RAM: ▲0.04MB] [CPU: ▼10.00ms] Passed 4 tests

A check of server-side resources used by ST Members List
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.50 ▲0.0439.80 ▲0.10
Dashboard /wp-admin3.36 ▲0.0143.76 ▼16.17
Posts /wp-admin/edit.php3.40 ▲0.0546.03 ▼7.75
Add New Post /wp-admin/post-new.php5.95 ▲0.0787.00 ▼16.19
Media Library /wp-admin/upload.php3.28 ▲0.0537.55 ▲1.24
Add New Member /wp-admin/post-new.php?post_type=members_list3.8755.48
All Members /wp-admin/edit.php?post_type=members_list3.3241.03

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

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

Browser metrics Passed 4 tests

ST Members List: an overview of browser usage
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,948 ▲20213.51 ▼1.238.79 ▲7.0440.92 ▼3.36
Dashboard /wp-admin2,233 ▲535.57 ▼0.0792.21 ▲5.6742.50 ▲3.66
Posts /wp-admin/edit.php2,135 ▲352.02 ▲0.0536.01 ▼5.7831.71 ▼3.76
Add New Post /wp-admin/post-new.php1,559 ▲3123.23 ▲0.14622.39 ▼12.7861.46 ▲3.15
Media Library /wp-admin/upload.php1,438 ▲384.25 ▲0.09102.36 ▲0.8841.72 ▼2.50
Add New Member /wp-admin/post-new.php?post_type=members_list2,6209.06196.9671.86
All Members /wp-admin/edit.php?post_type=members_list1,1081.9639.4532.28

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
You still need to fix the following
  • Zombie WordPress options were found after uninstall: 6 options
    • theysaidso_admin_options
    • can_compress_scripts
    • widget_theysaidso_widget
    • widget_recent-posts
    • db_upgraded
    • widget_recent-comments

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
The smoke test was a success, however most plugin functionality was not tested

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
The following issues need your attention
  • 14× PHP files trigger server-side errors or warnings when accessed directly (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/st-members-list/index.php:73
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/st-members-list/metabox/init.php:119
    • > PHP Fatal error
      Uncaught Error: Class 'WP_UnitTestCase' not found in wp-content/plugins/st-members-list/metabox/tests/cmb-tests-base.php:10
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_header() in wp-content/plugins/st-members-list/single-member.php:1
    • > PHP Fatal error
      Uncaught Error: Class 'WP_UnitTestCase' not found in wp-content/plugins/st-members-list/metabox/tests/cmb-tests-base.php:10
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/st-members-list/metabox/custom.php:4
    • > PHP Fatal error
      require_once(): Failed opening required '/includes/functions.php' (include_path='.:/usr/share/php') in wp-content/plugins/st-members-list/metabox/tests/bootstrap.php on line 24
    • > PHP Warning
      require_once(/includes/functions.php): failed to open stream: No such file or directory in wp-content/plugins/st-members-list/metabox/tests/bootstrap.php on line 24
    • > PHP Fatal error
      Uncaught Error: Class 'WP_UnitTestCase' not found in wp-content/plugins/st-members-list/metabox/tests/cmb-tests-base.php:10
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/st-members-list/metabox/example-functions.php:68

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 on the user side

Optimizations

Plugin configuration 86% from 29 tests

readme.txt 81% from 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
These attributes need to be fixed:
  • Contributors: Plugin contributors not specified
  • Screenshots: These screenshots require images: #1 (This screen shot description corresponds to screenshot-1.(png|jpg|jpeg|gif). Note that the screenshot is taken from), #2 (This is the second screen shot)
  • Plugin Name: Please replace "Plugin Name" with the name of your plugin on the first line ( === st-members-list === )
The official readme.txt is a good inspiration

st-members-list/index.php 92% from 13 tests

The main PHP file in "ST Members List" ver. 1.0 adds more information about the plugin and also serves as the entry point for this plugin
Please take the time to fix the following:
  • Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("st-members-list.php" instead of "index.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 plugin89,456 lines of code in 182 files:
LanguageFilesBlank linesComment linesLines of code
XML20047,741
PO File11912,73116,32929,151
PHP241,4482,3144,873
CSS91,0281,0534,176
Sass11168231,116
JavaScript6199175913
SVG100655
Markdown41720487
YAML290152
JSON300121
Bourne Shell119771

PHP code Passed 2 tests

This is a short overview of cyclomatic complexity and code structure for this plugin
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.36
Average class complexity28.76
▷ Minimum class complexity1.00
▷ Maximum class complexity121.00
Average method complexity2.79
▷ Minimum method complexity1.00
▷ Maximum method complexity17.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes21
▷ Abstract classes14.76%
▷ Concrete classes2095.24%
▷ Final classes00.00%
Methods325
▷ Static methods237.08%
▷ Public methods30995.08%
▷ Protected methods103.08%
▷ Private methods61.85%
Functions31
▷ Named functions31100.00%
▷ Anonymous functions00.00%
Constants6
▷ Global constants466.67%
▷ Class constants233.33%
▷ Public constants2100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
15 compressed PNG files occupy 0.02MB
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
metabox/images/ui-icons_888888_256x240.png5.23KB4.11KB▼ 21.49%
metabox/images/ui-icons_2e83ff_256x240.png4.27KB4.11KB▼ 3.78%
metabox/images/ui-bg_glass_75_dadada_1x400.png0.11KB0.16KB0.00%
metabox/images/ui-bg_glass_75_e6e6e6_1x400.png0.11KB0.14KB0.00%
css/grabbing.png0.11KB0.14KB0.00%