84% include-content-by-shortcode

Code Review | Include Content By Shortcode

WordPress plugin Include Content By Shortcode scored84%from 54 tests.

About plugin

  • Plugin page: include-content-b...
  • Plugin version: 0.4.1
  • PHP compatiblity: 5.2.4+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0.1-5.6
  • WordPress version: 6.3.1
  • First release: May 26, 2018
  • Latest release: Dec 13, 2020
  • Number of updates: 52
  • Update frequency: every 17.9 days
  • Top authors: kashanshah (100%)

Code review

54 tests

User reviews

4 reviews

Install metrics

50+ active /1,169 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 successfully, without throwing any errors or notices

Server metrics [RAM: ▲0.06MB] [CPU: ▼0.31ms] Passed 4 tests

Server-side resources used by Include Content By Shortcode
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.53 ▲0.0742.70 ▼0.71
Dashboard /wp-admin3.37 ▲0.0748.98 ▲0.78
Posts /wp-admin/edit.php3.42 ▲0.0649.18 ▼0.26
Add New Post /wp-admin/post-new.php5.96 ▲0.0790.30 ▼1.07
Media Library /wp-admin/upload.php3.30 ▲0.0636.20 ▲1.38
Settings /wp-admin/edit.php?post_type=icbscbks&page=include-content-by-shortcode3.2629.35
Included Contents /wp-admin/edit.php?post_type=icbscbks3.3455.85
Add New /wp-admin/post-new.php?post_type=icbscbks3.3650.06

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

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

Browser metrics Passed 4 tests

Checking browser requirements for Include Content By Shortcode
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,825 ▲6414.26 ▼0.091.85 ▲0.0543.44 ▼2.11
Dashboard /wp-admin2,228 ▲515.51 ▼0.1586.80 ▼18.8039.44 ▼5.27
Posts /wp-admin/edit.php2,133 ▲302.12 ▲0.1733.73 ▼2.2937.08 ▲1.81
Add New Post /wp-admin/post-new.php1,554 ▲2622.89 ▼0.15623.11 ▼3.0849.54 ▼2.62
Media Library /wp-admin/upload.php1,436 ▲364.13 ▼0.06102.61 ▲7.8142.66 ▲0.22
Settings /wp-admin/edit.php?post_type=icbscbks&page=include-content-by-shortcode8592.0225.7144.11
Included Contents /wp-admin/edit.php?post_type=icbscbks1,1131.9730.1232.83
Add New /wp-admin/post-new.php?post_type=icbscbks2,0173.9488.4247.01

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
The following items require your attention
  • This plugin does not fully uninstall, leaving 6 options in the database
    • theysaidso_admin_options
    • can_compress_scripts
    • db_upgraded
    • widget_recent-posts
    • widget_recent-comments
    • 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
Even though everything seems fine, this is not 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 items
  • 8× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_shortcode() in wp-content/plugins/include-content-by-shortcode/inc/shortcode.php:3
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/include-content-by-shortcode/inc/adding_meta_boxes.php:23
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_url() in wp-content/plugins/include-content-by-shortcode/inc/constants.php:2
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/include-content-by-shortcode/inc/registering_post_type.php:4
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_url() in wp-content/plugins/include-content-by-shortcode/inc/constants.php:2
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/include-content-by-shortcode/inc/adding_copy_shortcode_column.php:4
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_url() in wp-content/plugins/include-content-by-shortcode/inc/constants.php:2
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_url() in wp-content/plugins/include-content-by-shortcode/inc/constants.php:2

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
Everything seems fine on the user side

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 94% from 16 tests

Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
These attributes need your attention: The official readme.txt is a good inspiration

include-content-by-shortcode/include-content-by-shortcode.php 92% from 13 tests

The primary PHP file in "Include Content By Shortcode" version 0.4.1 is used by WordPress to initiate all plugin functionality
You should first fix the following items:
  • Description: Please don't use more than 140 characters for the plugin description (currently 214 characters long)

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 detected253 lines of code in 10 files:
LanguageFilesBlank linesComment linesLines of code
PHP94627250
CSS1103

PHP code Passed 2 tests

This is a very shot review of cyclomatic complexity and code structure
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.34
Average class complexity0.00
▷ Minimum class complexity0.00
▷ Maximum class complexity0.00
Average method complexity0.00
▷ Minimum method complexity0.00
▷ Maximum method complexity0.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes0
▷ Abstract classes00.00%
▷ Concrete classes00.00%
▷ Final classes00.00%
Methods0
▷ Static methods00.00%
▷ Public methods00.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions13
▷ Named functions1184.62%
▷ Anonymous functions215.38%
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
PNG images were not found in this plugin