10% cackle-live-chat

Code Review | Cackle Live Chat

WordPress plugin Cackle Live Chat scored10%from 54 tests.

About plugin

  • Plugin page: cackle-live-chat
  • Plugin version: 1.0.1
  • PHP version: 7.4.16
  • WordPress compatibility: 2.9.1-3.8.1
  • WordPress version: 6.3.1
  • First release: Jan 24, 2014
  • Latest release: Jan 24, 2014
  • Number of updates: 4
  • Update frequency: every 16.0 days
  • Top authors: cackle (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /1,714 total downloads

Benchmarks

Plugin footprint 40% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
It is recommended to fix the following installer errors
  • This plugin did not install gracefully
    • > Deprecated in wp-content/plugins/cackle-live-chat/cackle-live-chat.php+35
    Methods with the same name as their class will not be constructors in a future version of PHP; CackleChat has a deprecated constructor

Server metrics [RAM: ▼1.92MB] [CPU: ▼53.41ms] Passed 4 tests

A check of server-side resources used by Cackle Live Chat
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /2.07 ▼1.394.36 ▼36.96
Dashboard /wp-admin2.09 ▼1.226.68 ▼40.67
Posts /wp-admin/edit.php2.09 ▼1.276.44 ▼42.48
Add New Post /wp-admin/post-new.php2.09 ▼3.807.06 ▼93.51
Media Library /wp-admin/upload.php2.09 ▼1.146.82 ▼24.24
Cackle Live Chat /wp-admin/plugins.php?page=cackle-live-chat2.107.40

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

Analyzing filesystem and database footprints of this plugin
No storage issues were detected
Filesystem: 5 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-comments
can_compress_scripts
db_upgraded
widget_theysaidso_widget
theysaidso_admin_options
widget_recent-posts

Browser metrics Passed 4 tests

This is an overview of browser requirements for Cackle Live Chat
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,000 ▲24314.24 ▼0.1313.57 ▲11.3941.57 ▼3.88
Dashboard /wp-admin2,210 ▲224.88 ▼0.06108.26 ▲2.8540.71 ▼0.55
Posts /wp-admin/edit.php2,096 ▲72.04 ▲0.0137.92 ▼3.1834.12 ▼2.89
Add New Post /wp-admin/post-new.php1,536 ▲223.30 ▲0.13626.16 ▼39.2749.46 ▼4.88
Media Library /wp-admin/upload.php1,386 ▼54.29 ▲0.0796.94 ▼3.6141.35 ▼2.15
Cackle Live Chat /wp-admin/plugins.php?page=cackle-live-chat8382.0326.9927.77

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

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
It is recommended to fix the following
  • Uninstall procedure had uncaught errors
    • > Deprecated in wp-content/plugins/cackle-live-chat/cackle-live-chat.php+35
    Methods with the same name as their class will not be constructors in a future version of PHP; CackleChat has a deprecated constructor
  • Zombie WordPress options were found after uninstall: 6 options
    • widget_theysaidso_widget
    • can_compress_scripts
    • theysaidso_admin_options
    • widget_recent-comments
    • widget_recent-posts
    • db_upgraded

Smoke tests 50% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
These errors were triggered by the plugin
    • > GET request to /wp-admin/plugins.php?page=cackle-live-chat
    • > Deprecated in wp-content/plugins/cackle-live-chat/cackle-live-chat.php+35
    Methods with the same name as their class will not be constructors in a future version of PHP; CackleChat has a deprecated constructor

SRP 50% 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 items
  • 4× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Warning
      Use of undefined constant PLUGINDIR - assumed 'PLUGINDIR' (this will throw an Error in a future version of PHP) in wp-content/plugins/cackle-live-chat/cackle-live-chat.php on line 16
    • > PHP Warning
      Use of undefined constant WP_CONTENT_URL - assumed 'WP_CONTENT_URL' (this will throw an Error in a future version of PHP) in wp-content/plugins/cackle-live-chat/cackle-live-chat.php on line 11
    • > PHP Fatal error
      Uncaught Error: Call to undefined function cackle_live_chat_i() in wp-content/plugins/cackle-live-chat/manage.php:44
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/cackle-live-chat/cackle-live-chat.php:108

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
Everything seems fine on the user side

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 88% from 16 tests

The readme.txt file is important because it is parsed by WordPress.org for the public listing of your plugin
These attributes need your attention:
  • Screenshots: Screenshot #1 (Cackle Live Chat) image missing
  • Plugin Name: Please specify the plugin name on the first line ( === cackle-live-chat === )
Please take inspiration from this readme.txt

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

Analyzing the main PHP file in "Cackle Live Chat" version 1.0.1
16 characters long description:
Cackle Live Chat

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is a short overview of programming languages used in this plugin, detecting executable files
Good job! No executable or dangerous file extensions detected165 lines of code in 3 files:
LanguageFilesBlank linesComment linesLines of code
PHP23112134
CSS13031

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
Everything seems fine, there were no complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.36
Average class complexity5.00
▷ Minimum class complexity5.00
▷ Maximum class complexity5.00
Average method complexity1.80
▷ Minimum method complexity1.00
▷ Maximum method complexity4.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods5
▷ Static methods00.00%
▷ Public methods5100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions5
▷ Named functions5100.00%
▷ Anonymous functions00.00%
Constants1
▷ Global constants1100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Using a strong compression for your PNG files is a great way to speed-up your plugin
1 PNG file occupies 0.03MB with 0.02MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
screenshot-1.png27.24KB11.19KB▼ 58.91%