62% easy-sticky-sidebar

Code Review | WordPress CTA - WordPress Call To Action, Floating Content Plugin

WordPress plugin WordPress CTA - WordPress Call To Action, Floating Content Plugin scored 62% from 54 tests.

About plugin

  • Plugin page: easy-sticky-sidebar
  • Plugin version: 1.4.4
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.9-5.8
  • WordPress version: 5.9.2
  • First release: Jun 14, 2020
  • Latest release: Apr 4, 2022
  • Number of updates: 121
  • Update frequency: every 5.5 days
  • Top authors: blendmedia (100%)

Code review

54 tests

User reviews

4 reviews

Install metrics

1,000+ active / 10,795 total downloads

Benchmarks

Plugin footprint 65% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
This plugin's installer ran successfully

Server metrics [RAM: ▲0.55MB] [CPU: ▼309.09ms] Passed 4 tests

An overview of server-side resources used by WordPress CTA - WordPress Call To Action, Floating Content Plugin
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /4.03 ▲0.5177.08 ▲11.51
Dashboard /wp-admin3.97 ▲0.5642.77 ▼0.63
Posts /wp-admin/edit.php4.26 ▲0.6151.90 ▼31.05
Add New Post /wp-admin/post-new.php7.50 ▲0.53117.90 ▼1,209.90
Media Library /wp-admin/upload.php3.92 ▲0.6239.83 ▲5.24
WP CTA Dashboard /wp-admin/admin.php?page=easy-sticky-sidebars3.9338.80
Edit CTA /wp-admin/admin.php?page=edit-easy-sticky-sidebar3.9034.18
Add New /wp-admin/admin.php?page=add-easy-sticky-sidebar3.9637.01

Server storage [IO: ▲1.76MB] [DB: ▲0.01MB] Passed 3 tests

Input-output and database impact of this plugin
This plugin installed successfully
Filesystem: 46 new files
Database: 2 new tables, 2 new options
New tables
wp_sticky_cta
wp_sticky_cta_options
New WordPress options
easy_sticky_sidebar_default_attachment
easy_sticky_sidebar_version

Browser metrics Passed 4 tests

This is an overview of browser requirements for WordPress CTA - WordPress Call To Action, Floating Content Plugin
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /4,057 ▲31516.30 ▲0.7713.62 ▲3.123.74 ▲0.74
Dashboard /wp-admin3,040 ▲916.36 ▼0.12191.17 ▼36.46198.79 ▼83.27
Posts /wp-admin/edit.php2,802 ▲843.56 ▲0.13101.58 ▼16.78172.45 ▼28.86
Add New Post /wp-admin/post-new.php1,716 ▲7217.06 ▼2.33647.98 ▼46.07208.98 ▼12.44
Media Library /wp-admin/upload.php1,841 ▲1115.89 ▲0.18198.19 ▲11.99229.76 ▼20.12
WP CTA Dashboard /wp-admin/admin.php?page=easy-sticky-sidebars1,6955.71126.85205.47
Edit CTA /wp-admin/admin.php?page=edit-easy-sticky-sidebar1,4245.39110.95150.96
Add New /wp-admin/admin.php?page=add-easy-sticky-sidebar21,46213.46412.47259.14

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
It is recommended to fix the following
  • This plugin does not fully uninstall, leaving 2 tables in the database
    • wp_sticky_cta
    • wp_sticky_cta_options
  • The uninstall procedure has failed, leaving 2 options in the database
    • easy_sticky_sidebar_version
    • easy_sticky_sidebar_default_attachment

Smoke tests 25% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Please fix the following server-side errors
    • > GET request to /wp-admin/admin.php?page=edit-easy-sticky-sidebar
    • > Notice in wp-content/plugins/easy-sticky-sidebar/inc/ClassAdminOptions.php+95
    Undefined index: id

SRP 0% from 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
Please fix the following
  • 1× PHP files output non-empty strings when accessed directly via GET requests:
    • > /wp-content/plugins/easy-sticky-sidebar/views/view-tab-cta.php
  • 43× PHP files trigger server-side errors or warnings when accessed directly (only 10 are shown):
    • > PHP Notice
      Undefined variable: ctacontent in wp-content/plugins/easy-sticky-sidebar/views/view.php on line 22
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/easy-sticky-sidebar/inc/ClassGenerateStyle.php:11
    • > PHP Fatal error
      Uncaught Error: Call to undefined function is_admin() in wp-content/plugins/easy-sticky-sidebar/inc/ClassQuery.php:28
    • > PHP Notice
      Undefined variable: ctacontent in wp-content/plugins/easy-sticky-sidebar/views/view-tab-cta.php on line 17
    • > PHP Notice
      Trying to get property 'tab_cta_target_blank' of non-object in wp-content/plugins/easy-sticky-sidebar/views/view-tab-cta.php on line 7
    • > PHP Warning
      array_push() expects parameter 1 to be array, null given in wp-content/plugins/easy-sticky-sidebar/views/view-tab-cta.php on line 3
    • > PHP Warning
      array_push() expects parameter 1 to be array, null given in wp-content/plugins/easy-sticky-sidebar/views/view.php on line 8
    • > PHP Notice
      Trying to get property 'SSuprydp_action_option_url' of non-object in wp-content/plugins/easy-sticky-sidebar/views/view.php on line 11
    • > PHP Notice
      Undefined variable: ctacontent in wp-content/plugins/easy-sticky-sidebar/views/view-tab-cta.php on line 7
    • > PHP Notice
      Undefined variable: ctacontent in wp-content/plugins/easy-sticky-sidebar/views/view-tab-cta.php on line 11

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 issues were found

Optimizations

Plugin configuration 86% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file uses markdown syntax to describe your plugin to the world
Please fix the following attributes:
  • Tags: There are too many tags (20 tag instead of maximum 10)
You can look at the official readme.txt

easy-sticky-sidebar/sticky-sidebar.php 77% from 13 tests

The main file in "WordPress CTA - WordPress Call To Action, Floating Content Plugin" v. 1.4.4 serves as a complement to information provided in readme.txt and as the entry point to the plugin
The following require your attention:
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("easy-sticky-sidebar.php" instead of "sticky-sidebar.php")
  • Description: Please don't use more than 140 characters for the plugin description (currently 152 characters long)
  • Text Domain: You no longer need to specify the text domain since WordPress 4.6; it must be the same as the plugin slug

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | There should be no dangerous file extensions present in any WordPress plugin
There were no executable files found in this plugin13,316 lines of code in 34 files:
LanguageFilesBlank linesComment linesLines of code
CSS7285638,471
PHP198309613,094
JavaScript6134401,581
Markdown1570149
JSON10021

PHP code Passed 2 tests

This plugin's cyclomatic complexity and code structure detailed below
All good! No complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.32
Average class complexity23.75
▷ Minimum class complexity4.00
▷ Maximum class complexity65.00
Average method complexity2.86
▷ Minimum method complexity1.00
▷ Maximum method complexity13.00
Code structure
Namespaces1
Interfaces0
Traits0
Classes12
▷ Abstract classes00.00%
▷ Concrete classes12100.00%
▷ Final classes00.00%
Methods143
▷ Static methods32.10%
▷ Public methods10976.22%
▷ Protected methods64.20%
▷ Private methods2819.58%
Functions51
▷ Named functions4894.12%
▷ Anonymous functions35.88%
Constants5
▷ Global constants5100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

It is recommended to compress PNG files in your plugin to minimize bandwidth usage
2 PNG files occupy 0.07MB with 0.05MB in potential savings
Potential savings
Compression of 2 random PNG files using pngquant
FileSize - originalSize - compressedSavings
assets/img/ads.png72.00KB25.83KB▼ 64.12%
assets/fs-sprite.png1.07KB0.18KB▼ 82.82%