83% langbranch-shortcode

Code Review | LangBranch Shortcode

WordPress plugin LangBranch Shortcode scored83%from 54 tests.

About plugin

  • Plugin page: langbranch-shortcode
  • Plugin version: 1.0.1
  • PHP compatiblity: 7.4+
  • PHP version: 7.4.16
  • WordPress version: 6.3.1
  • First release: Jul 30, 2022
  • Latest release: Jul 31, 2022
  • Number of updates: 2
  • Update frequency: every 1.0 days
  • Top authors: hollen9 (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /154 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
This plugin's installer ran successfully

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

Server-side resources used by LangBranch Shortcode
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0136.29 ▼2.40
Dashboard /wp-admin3.31 ▼0.0345.14 ▼13.25
Posts /wp-admin/edit.php3.36 ▲0.0141.93 ▼1.51
Add New Post /wp-admin/post-new.php5.89 ▲0.0193.13 ▲7.07
Media Library /wp-admin/upload.php3.24 ▲0.0133.47 ▼1.58

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

How much does this plugin use your filesystem and database?
No storage issues were detected
Filesystem: 3 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-comments
theysaidso_admin_options
widget_recent-posts
widget_theysaidso_widget
db_upgraded
can_compress_scripts

Browser metrics Passed 4 tests

A check of browser resources used by LangBranch Shortcode
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,800 ▲6514.48 ▼0.161.64 ▼0.0339.19 ▼2.30
Dashboard /wp-admin2,209 ▲174.85 ▼0.0897.06 ▼11.2739.51 ▼3.08
Posts /wp-admin/edit.php2,089 ▼01.97 ▼0.0343.65 ▲4.5837.30 ▲4.70
Add New Post /wp-admin/post-new.php1,542 ▲918.40 ▼4.89612.51 ▼77.9645.75 ▼12.65
Media Library /wp-admin/upload.php1,388 ▼34.23 ▲0.0198.47 ▼4.0540.68 ▼6.92

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
  • The uninstall procedure has failed, leaving 6 options in the database
    • widget_theysaidso_widget
    • widget_recent-posts
    • theysaidso_admin_options
    • db_upgraded
    • widget_recent-comments
    • can_compress_scripts

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 items
  • 1× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_shortcode() in wp-content/plugins/langbranch-shortcode/main.php:97

User-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
No browser errors were detected

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 88% from 16 tests

The readme.txt file is important because it is parsed by WordPress.org for the public listing of your plugin
Attributes that require attention:
  • Contributors: The plugin contributors field is not present
  • Plugin Name: Write the name of your plugin instead of "Plugin Name" on the first line ( === langbranch-shortcode === )
The official readme.txt might help

langbranch-shortcode/main.php 92% from 13 tests

The entry point to "LangBranch Shortcode" version 1.0.1 is a PHP file that has certain tags in its header comment area
The following require your attention:
  • Main file name: Name the main plugin file the same as the plugin slug ("langbranch-shortcode.php" instead of "main.php")

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 plugin67 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code
PHP1102267

PHP code Passed 2 tests

This is a short overview of cyclomatic complexity and code structure for this plugin
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.74
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%
Functions3
▷ Named functions3100.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
PNG images were not found in this plugin