84% lana-shortcodes

Code Review | Lana Shortcodes

WordPress plugin Lana Shortcodes scored84%from 54 tests.

About plugin

  • Plugin page: lana-shortcodes
  • Plugin version: 1.2.0
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0-6.2
  • WordPress version: 6.3.1
  • First release: Oct 11, 2016
  • Latest release: Jun 23, 2023
  • Number of updates: 48
  • Update frequency: every 51.0 days
  • Top authors: lanadesign (60.42%)lanacodes (41.67%)

Code review

54 tests

User reviews

2 reviews

Install metrics

50+ active /3,903 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
Installer ran successfully

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

An overview of server-side resources used by Lana Shortcodes
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0139.11 ▼2.23
Dashboard /wp-admin3.32 ▲0.0144.56 ▼4.91
Posts /wp-admin/edit.php3.37 ▲0.0146.25 ▼0.86
Add New Post /wp-admin/post-new.php5.90 ▲0.0181.62 ▼4.98
Media Library /wp-admin/upload.php3.24 ▲0.0135.90 ▲2.07

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

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

Browser metrics Passed 4 tests

A check of browser resources used by Lana Shortcodes
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,806 ▲3513.55 ▼0.751.77 ▼0.2642.40 ▼2.25
Dashboard /wp-admin2,212 ▲274.86 ▼1.15107.68 ▼9.3741.08 ▼2.63
Posts /wp-admin/edit.php2,092 ▲32.00 ▼0.1137.44 ▼1.0637.56 ▲0.52
Add New Post /wp-admin/post-new.php1,537 ▲1823.05 ▲0.17679.86 ▲3.7560.22 ▲6.24
Media Library /wp-admin/upload.php1,394 ▲64.30 ▲0.0693.19 ▼17.2642.39 ▼4.45
Lana Shortcodes /wp-admin/lana-shortcodes-settings.php260.440.0715.33

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
It is recommended to fix the following
  • Zombie WordPress options detected upon uninstall: 6 options
    • widget_recent-posts
    • theysaidso_admin_options
    • db_upgraded
    • widget_recent-comments
    • widget_theysaidso_widget
    • can_compress_scripts

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Even though no errors were found, this is by no means an exhaustive test

SRP Passed 2 tests

🔹 Tests weight: 20 | The single-responsibility principle: PHP files have to remain inert when accessed directly, throwing no errors and performing no actions
Everything seems fine, however this is by no means an exhaustive test

User-side errors 0% from 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
These are user-side errors you should fix
    • > GET request to /wp-admin/lana-shortcodes-settings.php
    • > Network (severe)
    wp-admin/lana-shortcodes-settings.php - Failed to load resource: the server responded with a status of 404 (Not Found)

Optimizations

Plugin configuration Passed 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
2 plugin tags: bootstrap, bootstrap shortcodes

lana-shortcodes/lana-shortcodes.php Passed 13 tests

Analyzing the main PHP file in "Lana Shortcodes" version 1.2.0
36 characters long description:
Shortcodes with Bootstrap framework.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | An overview of files in this plugin; executable files are not allowed
No dangerous file extensions were detected27,158 lines of code in 26 files:
LanguageFilesBlank linesComment linesLines of code
CSS101,4323919,674
JavaScript141,8121,5876,860
PHP1118161336
SVG100288

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity
Average complexity per logical line of code0.23
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%
Functions17
▷ Named functions1694.12%
▷ Anonymous functions15.88%
Constants4
▷ Global constants4100.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
1 compressed PNG file occupies 0.03MB
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
assets/img/plugin-header.png28.91KB29.86KB0.00%