68% sticky-chat-widget

Code Review | Sticky Chat Widget: Click to chat, SMS, Email, Messages, Call Button, Live Chat and Live Support Button

WordPress plugin Sticky Chat Widget: Click to chat, SMS, Email, Messages, Call Button, Live Chat and Live Support Button scored68%from 54 tests.

About plugin

  • Plugin page: sticky-chat-widget
  • Plugin version: 1.2.5
  • PHP compatiblity: 5.4+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0-6.3
  • WordPress version: 6.3.1
  • First release: Mar 19, 2020
  • Latest release: Oct 3, 2023
  • Number of updates: 60
  • Update frequency: every 24.0 days
  • Top authors: gingerplugins (100%)

Code review

54 tests

User reviews

16 reviews

Install metrics

2,000+ active /17,845 total downloads

Benchmarks

Plugin footprint 65% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
This plugin's installer ran successfully

Server metrics [RAM: ▲0.66MB] [CPU: ▼1.29ms] Passed 4 tests

Server-side resources used by Sticky Chat Widget: Click to chat, SMS, Email, Messages, Call Button, Live Chat and Live Support Button
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.84 ▲0.3846.60 ▲3.90
Dashboard /wp-admin4.07 ▲0.7253.52 ▼12.36
Posts /wp-admin/edit.php4.18 ▲0.8358.75 ▲2.96
Add New Post /wp-admin/post-new.php6.65 ▲0.76105.22 ▲0.36
Media Library /wp-admin/upload.php3.99 ▲0.7647.34 ▲9.67
Go Pro /wp-admin/admin.php?page=sticky-chat-widget-upgrade-to-pro4.0739.45
Form Leads /wp-admin/admin.php?page=sticky-chat-widget-leads4.1041.19
Dashboard /wp-admin/admin.php?page=sticky-chat-widget4.0143.81

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

Filesystem and database footprint
This plugin was installed successfully
Filesystem: 93 new files
Database: 1 new table, 9 new options
New tables
wp_scw_contact_form_leads
New WordPress options
is_scw_database_migrated
widget_recent-posts
scw_install_date
sticky-chat-widget_review_date
widget_recent-comments
widget_theysaidso_widget
db_upgraded
can_compress_scripts
theysaidso_admin_options

Browser metrics Passed 4 tests

A check of browser resources used by Sticky Chat Widget: Click to chat, SMS, Email, Messages, Call Button, Live Chat and Live Support Button
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,819 ▲5814.25 ▼0.481.79 ▲0.0643.82 ▲1.68
Dashboard /wp-admin2,213 ▲365.55 ▼0.0387.87 ▼4.5579.97 ▲38.16
Posts /wp-admin/edit.php2,136 ▲361.95 ▼0.0938.32 ▲0.3333.66 ▼0.71
Add New Post /wp-admin/post-new.php1,579 ▲5218.57 ▼4.41632.16 ▼74.41158.58 ▲104.02
Media Library /wp-admin/upload.php1,424 ▲244.23 ▼0.01100.81 ▼6.8174.77 ▲30.80
Go Pro /wp-admin/admin.php?page=sticky-chat-widget-upgrade-to-pro1,4152.0326.3784.36
Form Leads /wp-admin/admin.php?page=sticky-chat-widget-leads1,1941.8831.4534.41
Dashboard /wp-admin/admin.php?page=sticky-chat-widget1,1123.8158.5099.58

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
The following items require your attention
  • Zombie tables were found after uninstall: 1 table
    • wp_scw_contact_form_leads
  • The uninstall procedure has failed, leaving 9 options in the database
    • scw_install_date
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • db_upgraded
    • widget_recent-posts
    • sticky-chat-widget_review_date
    • is_scw_database_migrated
    • can_compress_scripts
    • widget_recent-comments

Smoke tests 50% 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 0% 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
  • 25× PHP files perform the action of outputting non-empty strings when accessed directly (only 10 are shown):
    • > /wp-content/plugins/sticky-chat-widget/admin/templates/triggers.php
    • > /wp-content/plugins/sticky-chat-widget/admin/templates/subscribe.php
    • > /wp-content/plugins/sticky-chat-widget/index.php
    • > /wp-content/plugins/sticky-chat-widget/admin/templates/premium-features.php
    • > /wp-content/plugins/sticky-chat-widget/admin/templates/admin-notice.php
    • > /wp-content/plugins/sticky-chat-widget/admin/templates/admin-lists.php
    • > /wp-content/plugins/sticky-chat-widget/admin/templates/social-channels.php
    • > /wp-content/plugins/sticky-chat-widget/admin/templates/custom-css.php
    • > /wp-content/plugins/sticky-chat-widget/admin/admin.php
    • > /wp-content/plugins/sticky-chat-widget/includes/social-icons.php
  • 1× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Cannot access self:: when no class scope is active in wp-content/plugins/sticky-chat-widget/templates/template.php:2

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
There were no browser issues found

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 94% from 16 tests

Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
Attributes that need to be fixed:
  • Tags: There are too many tags (31 tag instead of maximum 10)
The official readme.txt might help

sticky-chat-widget/index.php 92% from 13 tests

The main PHP file in "Sticky Chat Widget: Click to chat, SMS, Email, Messages, Call Button, Live Chat and Live Support Button" ver. 1.2.5 adds more information about the plugin and also serves as the entry point for this plugin
Please make the necessary changes and fix the following:
  • Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("sticky-chat-widget.php" instead of "index.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are not allowed as they can serve as attack vectors
Success! There were no dangerous files found in this plugin27,194 lines of code in 68 files:
LanguageFilesBlank linesComment linesLines of code
SVG90129,306
PHP275696237,249
CSS17327256,224
JavaScript143452114,405
HTML10010

PHP code Passed 2 tests

Analyzing logical lines of code, cyclomatic complexity, and other code metrics
All good! No complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.51
Average class complexity81.50
▷ Minimum class complexity1.00
▷ Maximum class complexity174.00
Average method complexity6.46
▷ Minimum method complexity1.00
▷ Maximum method complexity54.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes4
▷ Abstract classes00.00%
▷ Concrete classes4100.00%
▷ Final classes00.00%
Methods59
▷ Static methods1830.51%
▷ Public methods59100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions2
▷ Named functions2100.00%
▷ Anonymous functions00.00%
Constants4
▷ Global constants4100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
7 compressed PNG files occupy 0.10MB
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
assets/admin/images/scw-icon.png0.52KB0.53KB0.00%
assets/admin/images/social-icons.png6.65KB2.92KB▼ 56.10%
assets/admin/img/flags@2x.png52.48KB56.11KB0.00%
assets/admin/img/flags.png19.57KB20.80KB0.00%
assets/admin/images/payment-card-icons.png4.35KB4.46KB0.00%