10% awesome-shortcodes-for-genesis

Code Review | Awesome Shortcodes For Genesis

WordPress plugin Awesome Shortcodes For Genesis scored10%from 54 tests.

About plugin

  • Plugin page: awesome-shortcode...
  • Plugin version: 1.1.8
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0-4.8
  • WordPress version: 6.3.1
  • First release: Aug 29, 2014
  • Latest release: Jul 26, 2017
  • Number of updates: 23
  • Update frequency: every 46.3 days
  • Top authors: sanjeevmohindra (100%)

Code review

54 tests

User reviews

1 review

Install metrics

200+ active /5,375 total downloads

Benchmarks

Plugin footprint 40% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
Please fix the following installer errors
  • This plugin did not install gracefully
    • > Deprecated in wp-content/plugins/awesome-shortcodes-for-genesis/ASG-shortcodes.php+151
    The behavior of unparenthesized expressions containing both '.' and '+'/'-' will change in PHP 8: '+'/'-' will take a higher precedence

Server metrics [RAM: ▼1.90MB] [CPU: ▼56.19ms] Passed 4 tests

Analyzing server-side resources used by Awesome Shortcodes For Genesis
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /2.09 ▼1.376.19 ▼33.78
Dashboard /wp-admin2.11 ▼1.205.12 ▼45.34
Posts /wp-admin/edit.php2.11 ▼1.256.53 ▼43.84
Add New Post /wp-admin/post-new.php2.11 ▼3.786.39 ▼101.81
Media Library /wp-admin/upload.php2.11 ▼1.127.68 ▼33.24
Awesome Shortcodes /wp-admin/options-general.php?page=asg-shortcode-plugin2.116.07

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

Filesystem and database footprint
No storage issues were detected
Filesystem: 16 new files
Database: no new tables, 6 new options
New WordPress options
db_upgraded
widget_recent-comments
widget_theysaidso_widget
can_compress_scripts
theysaidso_admin_options
widget_recent-posts

Browser metrics Passed 4 tests

This is an overview of browser requirements for Awesome Shortcodes For Genesis
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,808 ▲7313.19 ▼1.191.78 ▼0.1744.15 ▼4.71
Dashboard /wp-admin2,212 ▲275.82 ▲0.9398.36 ▼13.1040.03 ▼0.46
Posts /wp-admin/edit.php2,092 ▲32.03 ▼0.0336.51 ▼0.2034.70 ▼0.27
Add New Post /wp-admin/post-new.php1,519 ▼2417.66 ▼0.72680.29 ▲6.0053.47 ▲5.52
Media Library /wp-admin/upload.php1,397 ▲94.18 ▼0.0495.29 ▼11.7842.16 ▼1.75
Awesome Shortcodes /wp-admin/options-general.php?page=asg-shortcode-plugin1,1496.65204.8639.99

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
You still need to fix the following
  • The plugin did not uninstall gracefully
    • > Deprecated in wp-content/plugins/awesome-shortcodes-for-genesis/ASG-shortcodes.php+151
    The behavior of unparenthesized expressions containing both '.' and '+'/'-' will change in PHP 8: '+'/'-' will take a higher precedence
  • Zombie WordPress options detected upon uninstall: 6 options
    • widget_recent-posts
    • widget_recent-comments
    • can_compress_scripts
    • theysaidso_admin_options
    • db_upgraded
    • widget_theysaidso_widget

Smoke tests 25% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Smoke test failed, please fix the following
  • 3 occurences, only the last one shown
    • > GET request to /wp-admin/options-general.php?page=asg-shortcode-plugin
    • > Deprecated in wp-content/plugins/awesome-shortcodes-for-genesis/ASG-shortcodes.php+151
    The behavior of unparenthesized expressions containing both '.' and '+'/'-' will change in PHP 8: '+'/'-' will take a higher precedence
    • > GET request to /wp-admin/options-general.php?page=asg-shortcode-plugin
    • > Notice in wp-content/plugins/awesome-shortcodes-for-genesis/ASG-admin.php+10
    Undefined index: action
    • > GET request to /wp-admin/options-general.php?page=asg-shortcode-plugin
    • > Notice in wp-content/plugins/awesome-shortcodes-for-genesis/ASG-admin.php+19
    Undefined variable: message

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 take a closer look at the following
  • 2× 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/awesome-shortcodes-for-genesis/ASG-shortcodes.php:46
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_shortcode() in wp-content/plugins/awesome-shortcodes-for-genesis/ASG-shortcodes.php:46

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)
There are user-side issues you should fix
    • > GET request to /wp-admin/options-general.php?page=asg-shortcode-plugin
    • > Network (severe)
    https://feeds.feedburner.com/Techkle?format=sigpro - Failed to load resource: the server responded with a status of 403 ()
    • > GET request to /wp-admin/options-general.php?page=asg-shortcode-plugin
    • > Other (severe) in unknown
    chrome-error://chromewebdata/ - Refused to display 'https://developers.google.com/' in a frame because it set 'X-Frame-Options' to 'sameorigin'.

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

The readme.txt file is important because it is parsed by WordPress.org for the public listing of your plugin
7 plugin tags: page, toggle boxes, genesis, post, faq pages...

awesome-shortcodes-for-genesis/ASG-index.php 92% from 13 tests

The principal PHP file in "Awesome Shortcodes For Genesis" v. 1.1.8 is loaded by WordPress automatically on each request
Please make the necessary changes and fix the following:
  • Main file name: It is recommended to name the main PHP file as the plugin slug ("awesome-shortcodes-for-genesis.php" instead of "ASG-index.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of programming languages used in this plugin; dangerous file extensions are not allowed
Everything looks great! No dangerous files found in this plugin722 lines of code in 9 files:
LanguageFilesBlank linesComment linesLines of code
PHP51830278
CSS2623242
JavaScript202202

PHP code Passed 2 tests

A short review of cyclomatic complexity and code structure
All good! No complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.36
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%
Functions15
▷ Named functions15100.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
6 PNG files occupy 0.01MB with 0.00MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
Images/amazon-logo.png1.40KB1.60KB0.00%
Images/apple-logo.png3.11KB1.78KB▼ 42.67%
Images/asg-shortcodes.png0.34KB0.21KB▼ 40.06%
Images/asg-blank.png3.62KB0.09KB▼ 97.38%
Images/asg-arrow.png0.37KB0.47KB0.00%