83% children-excerpt-shortcode-plugin

Code Review | Name: Children Excerpt Shortcode

WordPress plugin Name: Children Excerpt Shortcodescored83%from 54 tests.

About plugin

  • Plugin page: children-excerpt-...
  • Plugin version: 1.3
  • PHP version: 7.4.16
  • WordPress compatibility: 2.9-3.8.1
  • WordPress version: 6.3.1
  • First release: Dec 12, 2011
  • Latest release: Mar 1, 2014
  • Number of updates: 22
  • Update frequency: every 36.8 days
  • Top authors: ChrisHurst (90.91%)MyWebsiteAdvisor (13.64%)

Code review

54 tests

User reviews

1 review

Install metrics

30+ active /2,531 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
Installer ran successfully

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

A check of server-side resources used by Name: Children Excerpt Shortcode
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0140.08 ▼9.85
Dashboard /wp-admin3.31 ▼0.0351.47 ▼16.71
Posts /wp-admin/edit.php3.37 ▲0.0159.71 ▲7.22
Add New Post /wp-admin/post-new.php5.89 ▲0.0187.08 ▼14.51
Media Library /wp-admin/upload.php3.24 ▲0.0134.40 ▲0.28

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

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

Browser metrics Passed 4 tests

This is an overview of browser requirements for Name: Children Excerpt Shortcode
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,789 ▲2814.35 ▲0.002.08 ▼0.3139.40 ▲0.08
Dashboard /wp-admin2,195 ▲185.61 ▼0.0483.56 ▼3.2140.03 ▼3.99
Posts /wp-admin/edit.php2,105 ▲52.02 ▲0.0742.07 ▲2.6746.34 ▲13.65
Add New Post /wp-admin/post-new.php1,526 ▼223.53 ▲0.38706.08 ▲27.6974.50 ▲3.47
Media Library /wp-admin/upload.php1,403 ▲64.18 ▼0.0394.62 ▼7.4940.25 ▼9.16

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
    • widget_recent-posts
    • can_compress_scripts
    • widget_recent-comments
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • db_upgraded

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for 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
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_shortcode() in wp-content/plugins/children-excerpt-shortcode-plugin/children-excerpt.php:33

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 90% from 29 tests

readme.txt 88% 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
Please fix the following attributes:
  • Screenshots: Add images for these screenshots: #1 (example use of the plugin shortcode.), #2 (example output of the plugin shortcode.)
  • Plugin Name: Please replace "Plugin Name" with the name of your plugin on the first line ( === Name: Children Excerpt Shortcode=== )
You can look at the official readme.txt

children-excerpt-shortcode-plugin/children-excerpt.php 92% from 13 tests

The main PHP file in "Name: Children Excerpt Shortcode" ver. 1.3 adds more information about the plugin and also serves as the entry point for this plugin
It is important to fix the following:
  • Main file name: Name the main plugin file the same as the plugin slug ("children-excerpt-shortcode-plugin.php" instead of "children-excerpt.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short review of files and their extensions; it is not recommended to include executable files
There were no executable files found in this plugin40 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code
PHP1293140

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.32
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%
Functions1
▷ Named functions1100.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
There are no PNG files in this plugin