84% genesis-simple-sidebars

Code Review | Genesis Simple Sidebars

WordPress plugin Genesis Simple Sidebars scored84%from 54 tests.

About plugin

  • Plugin page: genesis-simple-si...
  • Plugin version: 2.2.2
  • PHP version: 7.4.16
  • WordPress compatibility: 4.7.3-6.3
  • WordPress version: 6.3.1
  • First release: Jul 16, 2010
  • Latest release: Aug 7, 2023
  • Number of updates: 45
  • Update frequency: every 106.0 days
  • Top authors: nathanrice (53.33%)studiopress (33.33%)wpmuguru (17.78%)

Code review

54 tests

User reviews

27 reviews

Install metrics

20,000+ active /440,139 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
The plugin installed gracefully, with no errors

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

This is a short check of server-side resources used by Genesis Simple Sidebars
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0138.63 ▼4.45
Dashboard /wp-admin3.31 ▲0.0149.12 ▼1.82
Posts /wp-admin/edit.php3.36 ▲0.0150.34 ▲1.45
Add New Post /wp-admin/post-new.php5.89 ▲0.01116.31 ▲18.03
Media Library /wp-admin/upload.php3.23 ▲0.0139.70 ▲3.51

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

Input-output and database impact of this plugin
This plugin installed successfully
Filesystem: 23 new files
Database: no new tables, 6 new options
New WordPress options
can_compress_scripts
widget_theysaidso_widget
theysaidso_admin_options
widget_recent-posts
db_upgraded
widget_recent-comments

Browser metrics Passed 4 tests

A check of browser resources used by Genesis Simple Sidebars
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,792 ▲3114.41 ▼0.231.64 ▼0.1839.24 ▼6.64
Dashboard /wp-admin2,201 ▲245.62 ▼0.0791.13 ▼0.5241.43 ▼2.60
Posts /wp-admin/edit.php2,103 ▲61.98 ▼0.0334.47 ▲0.9135.87 ▼1.16
Add New Post /wp-admin/post-new.php1,548 ▲2223.04 ▲5.51679.26 ▼3.1849.14 ▼8.24
Media Library /wp-admin/upload.php1,397 ▼34.16 ▼0.11101.07 ▼12.4345.91 ▼1.58

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
These items require your attention
  • Zombie WordPress options were found after uninstall: 6 options
    • widget_theysaidso_widget
    • widget_recent-posts
    • theysaidso_admin_options
    • db_upgraded
    • widget_recent-comments
    • can_compress_scripts

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)
Even though everything seems fine, this is not an exhaustive test

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
The following issues need your attention
  • 5× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function Genesis_Simple_Sidebars() in wp-content/plugins/genesis-simple-sidebars/includes/views/admin-edit.php:8
    • > PHP Fatal error
      Uncaught Error: Class 'Genesis_Admin_Basic' not found in wp-content/plugins/genesis-simple-sidebars/includes/class-genesis-simple-sidebars-admin.php:15
    • > PHP Fatal error
      Uncaught Error: Call to undefined function Genesis_Simple_Sidebars() in wp-content/plugins/genesis-simple-sidebars/includes/views/term-edit-sidebar-form.php:8
    • > PHP Fatal error
      Uncaught Error: Call to undefined function Genesis_Simple_Sidebars() in wp-content/plugins/genesis-simple-sidebars/includes/views/entry-metabox-content.php:8
    • > PHP Fatal error
      Uncaught Error: Call to undefined function esc_html_e() in wp-content/plugins/genesis-simple-sidebars/includes/views/admin-main.php:10

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
No browser errors were detected

Optimizations

Plugin configuration 93% 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:
  • Plugin Name: Please specify the plugin name on the first line ( === genesis-simple-sidebars === )
You can look at the official readme.txt

genesis-simple-sidebars/plugin.php 92% from 13 tests

The primary PHP file in "Genesis Simple Sidebars" version 2.2.2 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 ("genesis-simple-sidebars.php" instead of "plugin.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short check of programming languages and file extensions; no executable files are allowed
Success! There were no dangerous files found in this plugin1,055 lines of code in 18 files:
LanguageFilesBlank linesComment linesLines of code
PHP13270472659
YAML1160158
PO File1379792
JavaScript116877
JSON20069

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.37
Average class complexity16.60
▷ Minimum class complexity5.00
▷ Maximum class complexity45.00
Average method complexity3.44
▷ Minimum method complexity1.00
▷ Maximum method complexity12.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes5
▷ Abstract classes00.00%
▷ Concrete classes5100.00%
▷ Final classes00.00%
Methods32
▷ Static methods00.00%
▷ Public methods2887.50%
▷ Protected methods412.50%
▷ Private methods00.00%
Functions17
▷ Named functions17100.00%
▷ Anonymous functions00.00%
Constants6
▷ Global constants6100.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
There are no PNG files in this plugin