84% liveagent

Code Review | LiveAgent - Omnichannel Help Desk & Live Chat Software

WordPress plugin LiveAgent - Omnichannel Help Desk & Live Chat Software scored 84% from 54 tests.

About plugin

  • Plugin page: liveagent
  • Plugin version: 4.4.3
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0.1-6.2
  • WordPress version: 6.3.1
  • First release: Jun 10, 2011
  • Latest release: Mar 29, 2023
  • Number of updates: 190
  • Update frequency: every 22.7 days
  • Top authors: jurajsim (100%)

Code review

54 tests

User reviews

17 reviews

Install metrics

700+ active / 40,028 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
Installer ran successfully

Server metrics [RAM: ▲0.42MB] [CPU: ▼6.56ms] Passed 4 tests

Analyzing server-side resources used by LiveAgent - Omnichannel Help Desk & Live Chat Software
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.89 ▲0.4342.85 ▼0.80
Dashboard /wp-admin3.75 ▲0.4551.17 ▲1.93
Posts /wp-admin/edit.php3.80 ▲0.4447.66 ▼0.57
Add New Post /wp-admin/post-new.php6.29 ▲0.4085.01 ▼26.81
Media Library /wp-admin/upload.php3.61 ▲0.3837.58 ▲6.44

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

Filesystem and database footprint
This plugin was installed successfully
Filesystem: 54 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-posts
can_compress_scripts
widget_recent-comments
db_upgraded
theysaidso_admin_options
widget_theysaidso_widget

Browser metrics Passed 4 tests

An overview of browser requirements for LiveAgent - Omnichannel Help Desk & Live Chat Software
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,829 ▲9414.06 ▼0.342.78 ▲1.0631.50 ▼17.90
Dashboard /wp-admin2,220 ▲325.43 ▲0.53133.97 ▲19.8488.51 ▲45.26
Posts /wp-admin/edit.php2,118 ▲292.58 ▲0.5755.96 ▲16.7637.05 ▲2.61
Add New Post /wp-admin/post-new.php1,694 ▲16022.87 ▼0.09667.09 ▲16.0530.93 ▼19.35
Media Library /wp-admin/upload.php1,408 ▲174.81 ▲0.51114.90 ▲13.8960.28 ▲14.57

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

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
Please fix the following items
  • This plugin does not fully uninstall, leaving 6 options in the database
    • widget_theysaidso_widget
    • widget_recent-comments
    • theysaidso_admin_options
    • db_upgraded
    • widget_recent-posts
    • can_compress_scripts

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Everything seems fine, however this is by no means an exhaustive test

SRP 50% from 2 tests

🔹 Tests weight: 20 | A shallow check of the single-responsibility principle; PHP files should perform no action - including output of placeholder text - and trigger no errors when accessed directly
Almost there! Just fix the following items
  • 17× PHP files trigger server errors when accessed directly (only 10 are shown):
    • > PHP Warning
      include_once(WP_PLUGIN_DIR/liveagent/Config.php): failed to open stream: No such file or directory in wp-content/plugins/liveagent/liveagent.php on line 18
    • > PHP Warning
      Use of undefined constant WP_PLUGIN_DIR - assumed 'WP_PLUGIN_DIR' (this will throw an Error in a future version of PHP) in wp-content/plugins/liveagent/Loader.php on line 11
    • > PHP Fatal error
      Uncaught Error: Class 'liveagent_Loader' not found in wp-content/plugins/liveagent/liveagent.php:33
    • > PHP Fatal error
      Uncaught Error: Class 'liveagent_Form_Validator_Base' not found in wp-content/plugins/liveagent/Form/Validator/Account.class.php:11
    • > PHP Fatal error
      Uncaught Error: Class 'liveagent_Form_Base' not found in wp-content/plugins/liveagent/Form/Settings/Account.class.php:11
    • > PHP Warning
      Use of undefined constant WP_PLUGIN_DIR - assumed 'WP_PLUGIN_DIR' (this will throw an Error in a future version of PHP) in wp-content/plugins/liveagent/liveagent.php on line 18
    • > PHP Warning
      Use of undefined constant WP_PLUGIN_DIR - assumed 'WP_PLUGIN_DIR' (this will throw an Error in a future version of PHP) in wp-content/plugins/liveagent/liveagent.php on line 32
    • > PHP Warning
      include_once(): Failed opening 'WP_PLUGIN_DIR/liveagent/Loader.php' for inclusion (include_path='.:/usr/share/php') in wp-content/plugins/liveagent/liveagent.php on line 32
    • > PHP Warning
      include_once(): Failed opening 'WP_PLUGIN_DIR/LIVEAGENT_PLUGIN_NAME/LoadClassException.class.php' for inclusion (include_path='.:/usr/share/php') in wp-content/plugins/liveagent/Loader.php on line 11
    • > PHP Warning
      include_once(WP_PLUGIN_DIR/LIVEAGENT_PLUGIN_NAME/LoadClassException.class.php): failed to open stream: No such file or directory in wp-content/plugins/liveagent/Loader.php on line 11

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
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 need to be fixed:
  • Tags: You are using too many tags: 15 tag instead of maximum 10
  • Screenshots: These screenshots require images: #1 (Creating a LiveAgent account), #2 (Example of a running chat from visitor's view), #3 (Screenshot from the application - Tickets grid), #4 (What you'll see after you connect an account), #5 (LiveAgent dashboard and leaderboards of your support agents), #6 (Example of a Knowledge Base generated by LiveAgent)
The official readme.txt might help

liveagent/liveagent.php Passed 13 tests

Analyzing the main PHP file in "LiveAgent - Omnichannel Help Desk & Live Chat Software" version 4.4.3
54 characters long description:
Plugin enables integration of Wordpress with LiveAgent

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 plugin5,372 lines of code in 29 files:
LanguageFilesBlank linesComment linesLines of code
SVG4011,686
PHP171893261,348
JavaScript33281241,243
CSS33810727
PO File2224359368

PHP code Passed 2 tests

This is a short overview of cyclomatic complexity and code structure for this plugin
This plugin has no cyclomatic complexity issues
Cyclomatic complexity
Average complexity per logical line of code0.34
Average class complexity12.75
▷ Minimum class complexity1.00
▷ Maximum class complexity42.00
Average method complexity2.88
▷ Minimum method complexity1.00
▷ Maximum method complexity27.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes16
▷ Abstract classes212.50%
▷ Concrete classes1487.50%
▷ Final classes00.00%
Methods102
▷ Static methods21.96%
▷ Public methods5553.92%
▷ Protected methods2423.53%
▷ Private methods2322.55%
Functions1
▷ Named functions1100.00%
▷ Anonymous functions00.00%
Constants38
▷ Global constants410.53%
▷ Class constants3489.47%
▷ Public constants34100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Often times overlooked, PNG files can occupy unnecessary space in your plugin
6 PNG files occupy 0.39MB with 0.10MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
resources/img/lock.png0.17KB0.18KB0.00%
resources/img/menu-icon.png0.80KB0.93KB0.00%
screenshot-5.png166.38KB55.59KB▼ 66.59%
screenshot-4.png114.07KB39.34KB▼ 65.51%
resources/img/ok_icon.png0.54KB0.66KB0.00%