83% enable-shortcodes-in-widgets-by-mstoic

Code Review | Enable Shortcodes in Widgets by Mstoic

WordPress plugin Enable Shortcodes in Widgets by Mstoic scored83%from 54 tests.

About plugin

  • Plugin page: enable-shortcodes...
  • Plugin version: 1.1
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0-4.6.1
  • WordPress version: 6.3.1
  • First release: Sep 21, 2016
  • Latest release: Sep 22, 2016
  • Number of updates: 3
  • Update frequency: every 0.7 days
  • Top authors: mstoic (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /892 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
This plugin's installer ran successfully

Server metrics [RAM: ▲0.00MB] [CPU: ▼4.39ms] Passed 4 tests

This is a short check of server-side resources used by Enable Shortcodes in Widgets by Mstoic
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0042.00 ▼4.06
Dashboard /wp-admin3.31 ▲0.0145.09 ▼10.02
Posts /wp-admin/edit.php3.36 ▲0.0047.34 ▼0.25
Add New Post /wp-admin/post-new.php5.89 ▲0.0089.58 ▼3.21
Media Library /wp-admin/upload.php3.24 ▲0.0035.17 ▲2.47

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

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

Browser metrics Passed 4 tests

Checking browser requirements for Enable Shortcodes in Widgets by Mstoic
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,800 ▲5413.38 ▼1.021.77 ▼0.1043.07 ▼5.60
Dashboard /wp-admin2,209 ▲215.90 ▼0.00101.93 ▼15.1038.30 ▼8.92
Posts /wp-admin/edit.php2,089 ▼02.06 ▲0.0740.87 ▲3.3734.58 ▼3.37
Add New Post /wp-admin/post-new.php1,543 ▲1018.10 ▼5.13630.73 ▼41.2660.44 ▲8.55
Media Library /wp-admin/upload.php1,391 ▲34.23 ▼0.0299.02 ▲0.9842.91 ▼0.77

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
You still need to fix the following
  • Zombie WordPress options were found after uninstall: 6 options
    • can_compress_scripts
    • theysaidso_admin_options
    • db_upgraded
    • widget_recent-comments
    • widget_theysaidso_widget
    • widget_recent-posts

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

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

SRP 50% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle applies for WordPress plugins as well - please make sure your PHP files perform no actions when accessed directly
Almost there! Just fix the following items
  • 1× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/enable-shortcodes-in-widgets-by-mstoic/mstoic-enable-shortcodes-widgets.php:31

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 86% from 29 tests

readme.txt 94% from 16 tests

You should put a lot of thought into formatting readme.txt as it is used by WordPress.org to prepare the public listing of your plugin
Attributes that require attention:
  • Plugin Name: Write the name of your plugin instead of "Plugin Name" on the first line ( === enable-shortcodes-in-widgets-by-mstoic === )
The official readme.txt might help

enable-shortcodes-in-widgets-by-mstoic/mstoic-enable-shortcodes-widgets.php 77% from 13 tests

The principal PHP file in "Enable Shortcodes in Widgets by Mstoic" v. 1.1 is loaded by WordPress automatically on each request
Please make the necessary changes and fix the following:
  • Text Domain: You no longer need to specify the text domain since WordPress 4.6; it must be the same as the plugin slug
  • Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("enable-shortcodes-in-widgets-by-mstoic.php" instead of "mstoic-enable-shortcodes-widgets.php")
  • Description: The description should be shorter than 140 characters (currently 151 characters long)

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is a short overview of programming languages used in this plugin, detecting executable files
No dangerous file extensions were detected11 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code
PHP142811

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.00
Average class complexity1.00
▷ Minimum class complexity1.00
▷ Maximum class complexity1.00
Average method complexity1.00
▷ Minimum method complexity1.00
▷ Maximum method complexity1.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods2
▷ Static methods00.00%
▷ Public methods2100.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

Using a strong compression for your PNG files is a great way to speed-up your plugin
There were not PNG files found in your plugin