84% jsm-show-registered-shortcodes

Code Review | JSM Show Registered Shortcodes

WordPress plugin JSM Show Registered Shortcodes scored84%from 54 tests.

About plugin

  • Plugin page: jsm-show-register...
  • Plugin version: 2.0.0
  • PHP compatiblity: 7.2.34+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.5-6.4.0
  • WordPress version: 6.3.1
  • First release: Jan 23, 2018
  • Latest release: Oct 18, 2023
  • Number of updates: 348
  • Update frequency: every 6.0 days
  • Top authors: jsmoriss (100%)

Code review

54 tests

User reviews

1 review

Install metrics

40+ active /4,014 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.03MB] [CPU: ▼0.21ms] Passed 4 tests

An overview of server-side resources used by JSM Show Registered Shortcodes
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.50 ▲0.0337.74 ▲2.08
Dashboard /wp-admin3.33 ▲0.0349.64 ▲4.24
Posts /wp-admin/edit.php3.38 ▲0.0343.43 ▼1.71
Add New Post /wp-admin/post-new.php5.91 ▲0.0396.27 ▲8.38
Media Library /wp-admin/upload.php3.25 ▲0.0232.77 ▼5.46

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

A short overview of filesystem and database impact
This plugin installed successfully
Filesystem: 4 new files
Database: no new tables, 6 new options
New WordPress options
widget_theysaidso_widget
theysaidso_admin_options
widget_recent-comments
widget_recent-posts
can_compress_scripts
db_upgraded

Browser metrics Passed 4 tests

A check of browser resources used by JSM Show Registered Shortcodes
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,912 ▲15114.18 ▼0.172.01 ▲0.3844.43 ▲2.56
Dashboard /wp-admin2,258 ▲805.60 ▼0.0787.32 ▼12.3645.40 ▲4.11
Posts /wp-admin/edit.php2,160 ▲601.99 ▲0.0136.11 ▼0.2034.03 ▲2.47
Add New Post /wp-admin/post-new.php1,593 ▲6718.15 ▼4.76587.95 ▼67.5679.52 ▲21.59
Media Library /wp-admin/upload.php1,466 ▲694.26 ▲0.0596.96 ▼18.8046.98 ▼1.92

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
It is recommended to fix the following
  • This plugin does not fully uninstall, leaving 6 options in the database
    • theysaidso_admin_options
    • can_compress_scripts
    • widget_recent-comments
    • widget_theysaidso_widget
    • db_upgraded
    • widget_recent-posts

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Everything seems fine, however this is by no means an exhaustive test

SRP 50% from 2 tests

🔹 Tests weight: 20 | A shallow check of the single-responsibility principle; PHP files should perform no action - including output of placeholder text - and trigger no errors when accessed directly
Almost there! Just fix the following items
  • 1× PHP files perform the task of outputting text when accessed with GET requests:
    • > /wp-content/plugins/jsm-show-registered-shortcodes/jsm-show-registered-shortcodes.php

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
Everything seems fine on the user side

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

The readme.txt file is important because it is parsed by WordPress.org for the public listing of your plugin
4 plugin tags: tools, debug, inspector, shortcodes

jsm-show-registered-shortcodes/jsm-show-registered-shortcodes.php Passed 13 tests

The principal PHP file in "JSM Show Registered Shortcodes" v. 2.0.0 is loaded by WordPress automatically on each request
114 characters long description:
Simple and lightweight plugin to show all registered shortcodes under a "Registered Shortcodes" toolbar menu item.

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 plugin96 lines of code in 2 files:
LanguageFilesBlank linesComment linesLines of code
PHP1393574
Markdown17022

PHP code Passed 2 tests

Analyzing cyclomatic complexity and code structure
This plugin has no cyclomatic complexity problems
Cyclomatic complexity
Average complexity per logical line of code0.33
Average class complexity8.00
▷ Minimum class complexity8.00
▷ Maximum class complexity8.00
Average method complexity2.17
▷ Minimum method complexity1.00
▷ Maximum method complexity5.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods6
▷ Static methods116.67%
▷ Public methods583.33%
▷ Protected methods00.00%
▷ Private methods116.67%
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

Often times overlooked, PNG files can occupy unnecessary space in your plugin
No PNG files were detected