84% bkc-wp-shortcodes

Code Review | Shortcodes

WordPress plugin Shortcodes scored 84% from 54 tests.

About plugin

  • Plugin page: bkc-wp-shortcodes
  • Plugin version: 1.0.4
  • PHP version: 7.4.16
  • WordPress version: 6.3.1
  • First release: Sep 26, 2017
  • Latest release: Oct 5, 2017
  • Number of updates: 8
  • Update frequency: every 1.3 days
  • Top authors: dineshc (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 1,589 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
Installer ran successfully

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

Analyzing server-side resources used by Shortcodes
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.79 ▲0.3238.31 ▲0.99
Dashboard /wp-admin3.62 ▲0.3148.24 ▲0.43
Posts /wp-admin/edit.php3.73 ▲0.3747.33 ▼0.03
Add New Post /wp-admin/post-new.php6.20 ▲0.3191.52 ▲5.51
Media Library /wp-admin/upload.php3.54 ▲0.3137.14 ▲4.91
Shortcodes /wp-admin/index.php?page=bkc-wp-shortcodes3.5131.63

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

A short overview of filesystem and database impact
No storage issues were detected
Filesystem: 6 new files
Database: no new tables, 6 new options
New WordPress options
theysaidso_admin_options
db_upgraded
widget_recent-posts
widget_theysaidso_widget
widget_recent-comments
can_compress_scripts

Browser metrics Passed 4 tests

A check of browser resources used by Shortcodes
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,804 ▲6913.21 ▼1.151.78 ▲0.0337.88 ▼0.07
Dashboard /wp-admin2,207 ▲195.76 ▼0.1294.36 ▼24.4837.74 ▼7.96
Posts /wp-admin/edit.php2,093 ▲42.01 ▲0.0235.24 ▼3.1934.02 ▲0.69
Add New Post /wp-admin/post-new.php1,536 ▲2223.27 ▲5.72576.23 ▼102.1750.51 ▼8.16
Media Library /wp-admin/upload.php1,392 ▲44.20 ▼0.1593.77 ▼2.7940.59 ▼1.97
Shortcodes /wp-admin/index.php?page=bkc-wp-shortcodes8902.0323.1233.32

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
The following items require your attention
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • widget_recent-posts
    • widget_recent-comments
    • can_compress_scripts
    • db_upgraded
    • theysaidso_admin_options
    • widget_theysaidso_widget

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
Everything seems fine, however this is by no means an exhaustive test

SRP 50% from 2 tests

🔹 Tests weight: 20 | It is important to ensure that your PHP files perform no action when accessed directly, respecting the single-responsibility principle
Please fix the following
  • 1× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function esc_html_e() in wp-content/plugins/bkc-wp-shortcodes/template/general.php:11

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

readme.txt 94% from 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
Please fix the following attributes:
  • Requires at least: Invalid version format
The official readme.txt might help

bkc-wp-shortcodes/bkc-wp-shortcodes.php Passed 13 tests

This is the main PHP file of "Shortcodes" version 1.0.4, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
56 characters long description:
This Plugin provides multiple wordpress core shortcodes.

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
Good job! No executable or dangerous file extensions detected1,008 lines of code in 5 files:
LanguageFilesBlank linesComment linesLines of code
PHP5781761,008

PHP code Passed 2 tests

Analyzing logical lines of code, cyclomatic complexity, and other code metrics
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.45
Average class complexity15.00
▷ Minimum class complexity3.00
▷ Maximum class complexity39.00
Average method complexity2.22
▷ Minimum method complexity1.00
▷ Maximum method complexity6.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes3
▷ Abstract classes00.00%
▷ Concrete classes3100.00%
▷ Final classes00.00%
Methods19
▷ Static methods315.79%
▷ Public methods19100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions1
▷ Named functions00.00%
▷ Anonymous functions1100.00%
Constants5
▷ Global constants5100.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