90% mslsselect

Code Review | MslsSelect

WordPress plugin MslsSelect scored90%from 54 tests.

About plugin

  • Plugin page: mslsselect
  • Plugin version: 2.3.0
  • PHP compatiblity: 7.4+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.6-6.4
  • WordPress version: 6.3.1
  • First release: Nov 7, 2014
  • Latest release: Nov 27, 2023
  • Number of updates: 24
  • Update frequency: every 137.8 days
  • Top authors: realloc (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /3,537 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
The plugin installed gracefully, with no errors

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

A check of server-side resources used by MslsSelect
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.48 ▲0.0142.79 ▼0.50
Dashboard /wp-admin3.32 ▲0.0152.11 ▲2.29
Posts /wp-admin/edit.php3.37 ▲0.0149.60 ▲0.61
Add New Post /wp-admin/post-new.php5.90 ▲0.0195.48 ▲1.39
Media Library /wp-admin/upload.php3.24 ▲0.0136.36 ▲5.41

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

Analyzing filesystem and database footprints of this plugin
No storage issues were detected
Filesystem: 4 new files
Database: no new tables, 7 new options
New WordPress options
can_compress_scripts
widget_recent-posts
msls
widget_recent-comments
widget_theysaidso_widget
theysaidso_admin_options
db_upgraded

Browser metrics Passed 4 tests

An overview of browser requirements for MslsSelect
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,792 ▲3014.22 ▲0.091.87 ▲0.1043.97 ▼4.32
Dashboard /wp-admin2,195 ▲185.58 ▼0.0392.14 ▼3.2541.39 ▲0.71
Posts /wp-admin/edit.php2,100 ▼32.01 ▲0.0038.75 ▲0.7134.31 ▲2.58
Add New Post /wp-admin/post-new.php1,526 ▼023.77 ▲0.31617.52 ▼20.9354.01 ▲5.15
Media Library /wp-admin/upload.php1,400 ▼04.21 ▼0.0397.65 ▼3.7541.98 ▼3.38

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
It is recommended to fix the following
  • Zombie WordPress options were found after uninstall: 7 options
    • widget_recent-posts
    • widget_recent-comments
    • widget_theysaidso_widget
    • can_compress_scripts
    • theysaidso_admin_options
    • msls
    • db_upgraded

Smoke tests Passed 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Even though no errors were found, this is by no means an exhaustive test

SRP Passed 2 tests

🔹 Tests weight: 20 | SRP (Single-Responsibility Principle) - PHP files must act as libraries and never output text or perform any action when accessed directly in a browser
Congratulations! This plugin passed the SRP test

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
Everything seems fine on the user side

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
10 plugin tags: localization, language, html select, multilingual, menu...

mslsselect/MslsSelect.php 92% from 13 tests

This is the main PHP file of "MslsSelect" version 2.3.0, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
You should first fix the following items:
  • Main file name: The principal plugin file should be the same as the plugin slug ("mslsselect.php" instead of "MslsSelect.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are not allowed as they can serve as attack vectors
Everything looks great! No dangerous files found in this plugin51 lines of code in 3 files:
LanguageFilesBlank linesComment linesLines of code
PHP1185539
JavaScript20012

PHP code Passed 2 tests

This is a very shot review of cyclomatic complexity and code structure
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.31
Average class complexity4.00
▷ Minimum class complexity4.00
▷ Maximum class complexity4.00
Average method complexity1.60
▷ Minimum method complexity1.00
▷ Maximum method complexity2.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods5
▷ Static methods480.00%
▷ Public methods5100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions1
▷ Named functions00.00%
▷ Anonymous functions1100.00%
Constants1
▷ Global constants00.00%
▷ Class constants1100.00%
▷ Public constants1100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
No PNG files were detected