89% add-multiple-sidebar

Code Review | Add Multiple Sidebar

WordPress plugin Add Multiple Sidebar scored89%from 54 tests.

About plugin

  • Plugin page: add-multiple-sidebar
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 4.5-5.7.1
  • WordPress version: 6.3.1
  • First release: Jan 28, 2019
  • Latest release: Apr 28, 2021
  • Number of updates: 7
  • Update frequency: every 117.4 days
  • Top authors: utsav72640 (100%)

Code review

54 tests

User reviews

1 review

Install metrics

50+ active /1,249 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
The plugin installed successfully, without throwing any errors or notices

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

This is a short check of server-side resources used by Add Multiple Sidebar
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.49 ▲0.0343.40 ▲2.30
Dashboard /wp-admin3.33 ▼0.0150.37 ▼14.61
Posts /wp-admin/edit.php3.38 ▲0.0348.26 ▼0.69
Add New Post /wp-admin/post-new.php5.91 ▲0.0382.71 ▼13.00
Media Library /wp-admin/upload.php3.26 ▲0.0335.90 ▼3.01

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

How much does this plugin use your filesystem and database?
This plugin installed successfully
Filesystem: 8 new files
Database: no new tables, 6 new options
New WordPress options
can_compress_scripts
widget_recent-posts
theysaidso_admin_options
db_upgraded
widget_theysaidso_widget
widget_recent-comments

Browser metrics Passed 4 tests

Checking browser requirements for Add Multiple Sidebar
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,789 ▲2814.25 ▼0.331.72 ▲0.1044.44 ▲0.76
Dashboard /wp-admin2,198 ▲275.63 ▲0.0896.83 ▲6.4340.86 ▲0.72
Posts /wp-admin/edit.php2,097 ▼31.99 ▼0.0236.12 ▼15.8134.12 ▼12.17
Add New Post /wp-admin/post-new.php1,526 ▼023.23 ▲0.12668.56 ▲4.3251.06 ▼7.05
Media Library /wp-admin/upload.php1,403 ▲64.17 ▼0.0497.19 ▼4.7643.10 ▲1.35

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
You still need to fix the following
  • The uninstall procedure has failed, leaving 6 options in the database
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • can_compress_scripts
    • db_upgraded
    • widget_recent-comments
    • widget_recent-posts

Smoke tests Passed 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)
Everything seems fine, however this is by no means an exhaustive test

SRP Passed 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
Everything seems fine, however this is by no means an exhaustive test

User-side errors Passed 1 test

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

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 88% 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:
  • Screenshots: These screenshots have no corresponding images in /assets: #1 (Add Multiple Sidebar Use Your Sidebar), #2 (Add Sidebar Name), #3 (Delete Your Sidebar)
  • Donate link: Please fix this invalid URI: "#"
You can take inspiration from this readme.txt

add-multiple-sidebar/sidebar.php 92% from 13 tests

The main file in "Add Multiple Sidebar" v. 1.0 serves as a complement to information provided in readme.txt and as the entry point to the plugin
It is important to fix the following:
  • Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("add-multiple-sidebar.php" instead of "sidebar.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
There were no executable files found in this plugin178 lines of code in 4 files:
LanguageFilesBlank linesComment linesLines of code
PHP11338102
JavaScript15947
PO File14524
CSS1005

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.26
Average class complexity14.00
▷ Minimum class complexity14.00
▷ Maximum class complexity14.00
Average method complexity3.17
▷ Minimum method complexity1.00
▷ Maximum method complexity11.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods6
▷ Static methods00.00%
▷ Public methods6100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions0
▷ Named functions00.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.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
3 PNG files occupy 0.07MB with 0.05MB in potential savings
Potential savings
Compression of 3 random PNG files using pngquant
FileSize - originalSize - compressedSavings
screenshot-1.png61.13KB18.02KB▼ 70.52%
screenshot-3.png9.31KB3.49KB▼ 62.54%
screenshot-2.png5.87KB2.31KB▼ 60.66%