62% eashortcode

Code Review | Eashortcode

WordPress plugin Eashortcode scored62%from 54 tests.

About plugin

  • Plugin page: eashortcode
  • Plugin version: 1.1.3
  • PHP version: 7.4.16
  • WordPress compatibility: 4.4-4.9
  • WordPress version: 6.3.1
  • First release: Jul 19, 2017
  • Latest release: Nov 18, 2017
  • Number of updates: 19
  • Update frequency: every 6.4 days
  • Top authors: lucvanderzandt (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /638 total downloads

Benchmarks

Plugin footprint 65% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
Install script ran successfully

Server metrics [RAM: ▼0.90MB] [CPU: ▼35.00ms] Passed 4 tests

Server-side resources used by Eashortcode
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.49 ▲0.0337.84 ▼4.08
Dashboard /wp-admin3.05 ▼0.3023.67 ▼38.96
Posts /wp-admin/edit.php3.05 ▼0.3126.00 ▼15.01
Add New Post /wp-admin/post-new.php3.05 ▼2.8423.37 ▼74.23
Media Library /wp-admin/upload.php3.05 ▼0.1820.76 ▼11.80
Eashortcode /wp-admin/options-general.php?page=eashortcode3.0522.94

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

Input-output and database impact of this plugin
This plugin was installed successfully
Filesystem: 6 new files
Database: no new tables, 6 new options
New WordPress options
theysaidso_admin_options
widget_recent-comments
can_compress_scripts
widget_recent-posts
db_upgraded
widget_theysaidso_widget

Browser metrics Passed 4 tests

Checking browser requirements for Eashortcode
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,834 ▲8813.62 ▼0.611.92 ▼0.0239.38 ▼5.71
Dashboard /wp-admin2,212 ▲245.85 ▼0.00103.16 ▼14.0742.12 ▼2.78
Posts /wp-admin/edit.php2,101 ▲122.01 ▼0.0339.56 ▲0.5833.39 ▼0.91
Add New Post /wp-admin/post-new.php1,545 ▲318.34 ▲0.11598.13 ▼15.7656.02 ▼2.24
Media Library /wp-admin/upload.php1,394 ▲64.15 ▼0.07101.76 ▲7.6541.99 ▲0.74
Eashortcode /wp-admin/options-general.php?page=eashortcode8002.0626.6725.27

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
These items require your attention
  • This plugin cannot be uninstalled
    • > Notice in wp-content/plugins/eashortcode/class-eashortcode-plugin-settings.php+58
    Trying to access array offset on value of type bool
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • theysaidso_admin_options
    • widget_recent-posts
    • widget_theysaidso_widget
    • can_compress_scripts
    • widget_recent-comments
    • db_upgraded

Smoke tests 25% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Smoke test failed, please fix the following
  • 4 occurences, only the last one shown
    • > GET request to /wp-admin/options-general.php?page=eashortcode
    • > Notice in wp-content/plugins/eashortcode/class-eashortcode-plugin-settings.php+90
    Trying to access array offset on value of type bool

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
  • 1× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/eashortcode/class-eashortcode-plugin.php:19

User-side errors 0% from 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
There are user-side issues you should fix
    • > GET request to /wp-admin/options-general.php?page=eashortcode
    • > Javascript (severe) in unknown
    /wp-content/plugins/eashortcode/js/script.js?ver=6.3.1 47:4 Uncaught ReferenceError: tinymce is not defined
    • > GET request to /wp-admin/options-general.php?page=eashortcode
    • > Network (severe)
    wp-json/wc/v2/products - Failed to load resource: the server responded with a status of 404 (Not Found)

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
3 plugin tags: button, woocommerce, shortcode

eashortcode/class-eashortcode-plugin.php 92% from 13 tests

The primary PHP file in "Eashortcode" version 1.1.3 is used by WordPress to initiate all plugin functionality
Please take the time to fix the following:
  • Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("eashortcode.php" instead of "class-eashortcode-plugin.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
Good job! No executable or dangerous file extensions detected192 lines of code in 3 files:
LanguageFilesBlank linesComment linesLines of code
PHP22062124
JavaScript1102068

PHP code Passed 2 tests

An overview of cyclomatic complexity and code structure
Everything seems fine, there were no complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.06
Average class complexity2.00
▷ Minimum class complexity1.00
▷ Maximum class complexity3.00
Average method complexity1.17
▷ Minimum method complexity1.00
▷ Maximum method complexity3.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes2
▷ Abstract classes00.00%
▷ Concrete classes2100.00%
▷ Final classes00.00%
Methods12
▷ Static methods00.00%
▷ Public methods12100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions0
▷ Named functions00.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
1 compressed PNG file occupies 0.00MB
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
img/icon.png0.87KB1.24KB0.00%