84% chat-button-for-isl-pronto

Code Review | Chat button for ISL Pronto

WordPress plugin Chat button for ISL Pronto scored84%from 54 tests.

About plugin

  • Plugin page: chat-button-for-i...
  • Plugin version: 1.2
  • PHP compatiblity: 7.4+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.0-6.1.1
  • WordPress version: 6.3.1
  • First release: Jan 19, 2021
  • Latest release: Feb 9, 2023
  • Number of updates: 8
  • Update frequency: every 94.8 days
  • Top authors: ddean (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /436 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
Installer ran successfully

Server metrics [RAM: ▲0.08MB] [CPU: ▲1.34ms] Passed 4 tests

Analyzing server-side resources used by Chat button for ISL Pronto
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.53 ▲0.0749.21 ▲6.72
Dashboard /wp-admin3.39 ▲0.0853.75 ▲4.56
Posts /wp-admin/edit.php3.50 ▲0.1451.21 ▲2.61
Add New Post /wp-admin/post-new.php5.97 ▲0.08103.39 ▲0.42
Media Library /wp-admin/upload.php3.31 ▲0.0836.21 ▼2.23
ISL Pronto settings /wp-admin/options-general.php?page=dd-isl-pronto3.2831.07

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

A short overview of filesystem and database impact
This plugin installed successfully
Filesystem: 2 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-posts
db_upgraded
theysaidso_admin_options
widget_recent-comments
can_compress_scripts
widget_theysaidso_widget

Browser metrics Passed 4 tests

Chat button for ISL Pronto: an overview of browser usage
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,819 ▲5813.21 ▼1.381.79 ▲0.1239.00 ▼5.20
Dashboard /wp-admin2,228 ▲255.85 ▼0.0198.37 ▼7.9937.75 ▼5.80
Posts /wp-admin/edit.php2,104 ▲42.04 ▲0.0133.62 ▼4.0032.24 ▼1.17
Add New Post /wp-admin/post-new.php1,554 ▲323.00 ▼0.25666.74 ▲51.1760.59 ▲4.07
Media Library /wp-admin/upload.php1,404 ▲44.20 ▲0.0198.82 ▼18.7544.45 ▼6.06
ISL Pronto settings /wp-admin/options-general.php?page=dd-isl-pronto9092.0326.5129.54

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
Please fix the following items
  • Zombie WordPress options detected upon uninstall: 6 options
    • db_upgraded
    • widget_recent-comments
    • theysaidso_admin_options
    • can_compress_scripts
    • widget_theysaidso_widget
    • widget_recent-posts

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
Everything seems fine, however this is by no means an exhaustive test

SRP 50% from 2 tests

🔹 Tests weight: 20 | SRP (Single-Responsibility Principle) - PHP files must act as libraries and never output text or perform any action when accessed directly in a browser
Please take a closer look at the following
  • 1× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_shortcode() in wp-content/plugins/chat-button-for-isl-pronto/chat-button-for-isl-pronto.php:61

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
No browser errors were detected

Optimizations

Plugin configuration 93% from 29 tests

readme.txt Passed 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
2 plugin tags: chat, isl-pronto

chat-button-for-isl-pronto/chat-button-for-isl-pronto.php 85% from 13 tests

"Chat button for ISL Pronto" version 1.2's main PHP file describes plugin functionality and also serves as the entry point to any WordPress functionality
You should first fix the following items:
  • Text Domain: You no longer need to specify the text domain since WordPress 4.6; it must be the same as the plugin slug
  • Requires PHP: Required version must be the same as the one declared in readme.txt ("7.2" instead of "7.4")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are considered dangerous and should not be included with any WordPress plugin
There were no executable files found in this plugin238 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code
PHP151103238

PHP code Passed 2 tests

Analyzing cyclomatic complexity and code structure
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.28
Average class complexity27.00
▷ Minimum class complexity27.00
▷ Maximum class complexity27.00
Average method complexity2.24
▷ Minimum method complexity1.00
▷ Maximum method complexity14.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods22
▷ Static methods14.55%
▷ Public methods1881.82%
▷ Protected methods00.00%
▷ Private methods418.18%
Functions1
▷ Named functions00.00%
▷ Anonymous functions1100.00%
Constants1
▷ Global constants00.00%
▷ Class constants1100.00%
▷ Public constants1100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Often times overlooked, PNG files can occupy unnecessary space in your plugin
PNG images were not found in this plugin