78% tiledesk-live-chat

Code Review | Tiledesk — Live Chat and Chatbots Integration

WordPress plugin Tiledesk — Live Chat and Chatbots Integration scored78%from 54 tests.

About plugin

  • Plugin page: tiledesk-live-chat
  • Plugin version: 1.0.8
  • PHP compatiblity: 7.0+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.0-6.3.2
  • WordPress version: 6.3.1
  • First release: Feb 15, 2023
  • Latest release: Oct 17, 2023
  • Number of updates: 11
  • Update frequency: every 22.2 days
  • Top authors: tiledesk (100%)

Code review

54 tests

User reviews

1 review

Install metrics

40+ active /971 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
The plugin installed gracefully, with no errors

Server metrics [RAM: ▲0.03MB] [CPU: ▼0.25ms] Passed 4 tests

Server-side resources used by Tiledesk — Live Chat and Chatbots Integration
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.49 ▲0.0345.26 ▲6.43
Dashboard /wp-admin3.34 ▲0.0443.65 ▼0.20
Posts /wp-admin/edit.php3.40 ▲0.0343.68 ▼5.78
Add New Post /wp-admin/post-new.php5.95 ▲0.0581.20 ▼1.43
Media Library /wp-admin/upload.php3.27 ▲0.0340.68 ▲7.65

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

A short overview of filesystem and database impact
This plugin was installed successfully
Filesystem: 15 new files
Database: no new tables, 7 new options
New WordPress options
widget_recent-posts
widget_theysaidso_widget
db_upgraded
can_compress_scripts
widget_recent-comments
theysaidso_admin_options
tiledesk-async-load

Browser metrics Passed 4 tests

This is an overview of browser requirements for Tiledesk — Live Chat and Chatbots Integration
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,815 ▲5414.36 ▲0.012.46 ▲0.8944.87 ▲1.85
Dashboard /wp-admin2,220 ▲435.60 ▼0.0781.68 ▼6.6284.42 ▲44.57
Posts /wp-admin/edit.php2,125 ▲222.02 ▼0.0134.80 ▼8.4632.54 ▼6.24
Add New Post /wp-admin/post-new.php1,700 ▲16322.39 ▲4.26700.90 ▲51.1255.82 ▼20.12
Media Library /wp-admin/upload.php1,425 ▲224.25 ▼0.02100.46 ▲6.8071.00 ▲27.42

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
You still need to fix the following
  • This plugin does not fully uninstall, leaving 7 options in the database
    • db_upgraded
    • theysaidso_admin_options
    • widget_recent-comments
    • can_compress_scripts
    • tiledesk-async-load
    • widget_recent-posts
    • widget_theysaidso_widget

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Even though everything seems fine, this is not an exhaustive test

SRP 0% 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× PHP files output non-empty strings when accessed directly via GET requests:
    • > /wp-content/plugins/tiledesk-live-chat/templates/options.php
  • 3× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/tiledesk-live-chat/tiledesk-live-chat.php:218
    • > PHP Fatal error
      Uncaught Error: Call to undefined function esc_url() in wp-content/plugins/tiledesk-live-chat/templates/footer-admin.php:3
    • > PHP Fatal error
      Uncaught Error: Call to undefined function wp_json_encode() in wp-content/plugins/tiledesk-live-chat/templates/footer-embed.php:2

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)
Everything seems fine on the user side

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 88% from 16 tests

You should put a lot of thought into formatting readme.txt as it is used by WordPress.org to prepare the public listing of your plugin
Attributes that require attention:
  • Tags: Too many tags (19 tag instead of maximum 10); only the first 5 tags are used in your directory listing
  • Screenshots: These screenshots need descriptions #10, #11, #9 in tiledesk-live-chat/assets to your readme.txt
The official readme.txt is a good inspiration

tiledesk-live-chat/tiledesk-live-chat.php Passed 13 tests

The entry point to "Tiledesk — Live Chat and Chatbots Integration" version 1.0.8 is a PHP file that has certain tags in its header comment area
109 characters long description:
Add Tiledesk Live Chat into your site allowing you to build complex conversational bots in just a few clicks.

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
Everything looks great! No dangerous files found in this plugin657 lines of code in 7 files:
LanguageFilesBlank linesComment linesLines of code
CSS26712364
PHP44355181
JavaScript11330112

PHP code Passed 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
Everything seems fine, there were no complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.23
Average class complexity16.00
▷ Minimum class complexity16.00
▷ Maximum class complexity16.00
Average method complexity2.15
▷ Minimum method complexity1.00
▷ Maximum method complexity8.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods13
▷ Static methods323.08%
▷ Public methods13100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions1
▷ Named functions1100.00%
▷ Anonymous functions00.00%
Constants9
▷ Global constants111.11%
▷ Class constants888.89%
▷ Public constants8100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
6 PNG files occupy 0.13MB with 0.04MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
media/img/color-pallete.png75.64KB34.31KB▼ 54.64%
media/img/checkmark.png0.43KB0.28KB▼ 34.31%
media/img/blocks-bg.png7.75KB8.95KB0.00%
media/img/icon.png0.15KB0.13KB▼ 15.82%
media/img/brand-logo.png1.29KB0.74KB▼ 43.17%