84% shortcode-ui-richtext

Code Review | Shortcake (Shortcode UI) Richtext

WordPress plugin Shortcake (Shortcode UI) Richtext scored84%from 54 tests.

About plugin

  • Plugin page: shortcode-ui-rich...
  • Plugin version: 1.3
  • PHP version: 7.4.16
  • WordPress compatibility: 4.5-4.9.4
  • WordPress version: 6.3.1
  • First release: Aug 26, 2016
  • Latest release: Mar 24, 2018
  • Number of updates: 13
  • Update frequency: every 44.2 days
  • Top authors: mihai2u (100%)

Code review

54 tests

User reviews

1 review

Install metrics

600+ active /22,278 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
Install script ran successfully

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

This is a short check of server-side resources used by Shortcake (Shortcode UI) Richtext
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0135.19 ▼2.98
Dashboard /wp-admin3.32 ▲0.0142.81 ▼4.91
Posts /wp-admin/edit.php3.37 ▲0.0144.10 ▲0.22
Add New Post /wp-admin/post-new.php5.90 ▲0.0187.51 ▼2.12
Media Library /wp-admin/upload.php3.24 ▲0.0137.98 ▲3.97

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

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

Browser metrics Passed 4 tests

An overview of browser requirements for Shortcake (Shortcode UI) Richtext
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,793 ▲3214.52 ▼0.031.68 ▲0.0937.15 ▼3.68
Dashboard /wp-admin2,199 ▲285.62 ▲0.0491.17 ▲4.9238.22 ▼2.22
Posts /wp-admin/edit.php2,100 ▲32.00 ▲0.0140.12 ▲6.6835.81 ▼3.01
Add New Post /wp-admin/post-new.php1,530 ▼722.97 ▲4.79587.77 ▼46.0058.03 ▼13.28
Media Library /wp-admin/upload.php1,400 ▼34.19 ▲0.0596.46 ▲0.6640.71 ▼0.98

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
These items require your attention
  • Zombie WordPress options detected upon uninstall: 6 options
    • widget_recent-comments
    • db_upgraded
    • theysaidso_admin_options
    • widget_recent-posts
    • can_compress_scripts
    • widget_theysaidso_widget

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Everything seems fine, however 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
Please fix the following
  • 6× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Class 'WP_UnitTestCase' not found in wp-content/plugins/shortcode-ui-richtext/tests/phpunit/test-class-plugin-base.php:15
    • > PHP Fatal error
      Uncaught Error: Call to undefined function ShortcodeUiRichtext\\plugin_dir_path() in wp-content/plugins/shortcode-ui-richtext/php/class-plugin-base.php:133
    • > PHP Fatal error
      Uncaught Error: Class 'WP_UnitTestCase' not found in wp-content/plugins/shortcode-ui-richtext/tests/phpunit/test-shortcode-ui-richtext.php:15
    • > PHP Fatal error
      Uncaught Error: Class 'ShortcodeUiRichtext\\Plugin_Base' not found in wp-content/plugins/shortcode-ui-richtext/php/class-plugin.php:13
    • > PHP Fatal error
      Uncaught Error: Call to undefined function ShortcodeUiRichtext\\plugin_dir_path() in wp-content/plugins/shortcode-ui-richtext/php/class-plugin-base.php:133
    • > PHP Fatal error
      Uncaught Error: Class 'WP_UnitTestCase' not found in wp-content/plugins/shortcode-ui-richtext/tests/phpunit/test-class-plugin.php:15

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
There were no browser issues found

Optimizations

Plugin configuration 93% from 29 tests

readme.txt Passed 16 tests

The readme.txt file is an important file in your plugin as it is parsed by WordPress.org to prepare the public listing of your plugin
1 plugin tags: shortcodes

shortcode-ui-richtext/shortcode-ui-richtext.php 85% from 13 tests

"Shortcake (Shortcode UI) Richtext" version 1.3's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
It is important to fix the following:
  • Domain Path: The domain path points to an invalid folder, "/languages" does not exist
  • Text Domain: The text domain name should consist of only dashes and lowercase characters

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of file extensions present in this plugin and a short test that no dangerous files are bundled with this plugin
Good job! No executable or dangerous file extensions detected419 lines of code in 14 files:
LanguageFilesBlank linesComment linesLines of code
PHP956248172
Markdown1470101
JavaScript1201790
XML11028
JSON11018
CSS12310

PHP code Passed 2 tests

A short review of cyclomatic complexity and code structure
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.13
Average class complexity2.14
▷ Minimum class complexity1.00
▷ Maximum class complexity9.00
Average method complexity1.50
▷ Minimum method complexity1.00
▷ Maximum method complexity8.00
Code structure
Namespaces1
Interfaces0
Traits0
Classes7
▷ Abstract classes114.29%
▷ Concrete classes685.71%
▷ Final classes00.00%
Methods17
▷ Static methods00.00%
▷ Public methods17100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions4
▷ Named functions375.00%
▷ Anonymous functions125.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
There are no PNG files in this plugin