73% chirpbox-chat

Code Review | Chirpbox Chat

WordPress plugin Chirpbox Chat scored73%from 54 tests.

About plugin

  • Plugin page: chirpbox-chat
  • Plugin version: 1.2.2
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0.1-4.5.2
  • WordPress version: 6.3.1
  • First release: Jun 7, 2016
  • Latest release: Jun 14, 2016
  • Number of updates: 13
  • Update frequency: every 4.0 days
  • Top authors: chirpbox (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /677 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
Install script ran successfully

Server metrics [RAM: ▲0.07MB] [CPU: ▼1.12ms] Passed 4 tests

A check of server-side resources used by Chirpbox Chat
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.53 ▲0.0740.44 ▼2.40
Dashboard /wp-admin3.37 ▲0.0651.74 ▲2.83
Posts /wp-admin/edit.php3.48 ▲0.1245.75 ▲1.22
Add New Post /wp-admin/post-new.php5.97 ▲0.0884.84 ▼6.13
Media Library /wp-admin/upload.php3.29 ▲0.0636.81 ▲7.03
Chirpbox Chat /wp-admin/options-general.php?page=chirpbox-chat3.2528.62

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

Analyzing filesystem and database footprints of this plugin
This plugin installed successfully
Filesystem: 22 new files
Database: no new tables, 6 new options
New WordPress options
widget_theysaidso_widget
theysaidso_admin_options
can_compress_scripts
db_upgraded
widget_recent-posts
widget_recent-comments

Browser metrics Passed 4 tests

An overview of browser requirements for Chirpbox Chat
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,916 ▲18113.57 ▼0.708.17 ▲5.9842.31 ▼8.51
Dashboard /wp-admin2,211 ▲235.79 ▲0.90100.01 ▼15.6941.84 ▼7.46
Posts /wp-admin/edit.php2,097 ▲82.02 ▼0.0435.90 ▼0.0132.68 ▼0.19
Add New Post /wp-admin/post-new.php1,521 ▲223.10 ▼0.10647.55 ▼62.4851.15 ▼6.46
Media Library /wp-admin/upload.php1,396 ▲84.20 ▼0.1897.68 ▼8.5142.45 ▼5.16
Chirpbox Chat /wp-admin/options-general.php?page=chirpbox-chat8002.0624.2329.85

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
It is recommended to fix the following
  • Zombie WordPress options detected upon uninstall: 6 options
    • db_upgraded
    • can_compress_scripts
    • widget_recent-posts
    • theysaidso_admin_options
    • widget_recent-comments
    • widget_theysaidso_widget

Smoke tests 25% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Almost there, just fix the following server-side errors
    • > GET request to /wp-admin/options-general.php?page=chirpbox-chat
    • > Notice in wp-content/plugins/chirpbox-chat/admin/partials/chirpbox-chat-admin-display.php+27
    Trying to access array offset on value of type bool

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 fix the following items
  • 1× PHP files output non-empty strings when accessed directly via GET requests:
    • > /wp-content/plugins/chirpbox-chat/public/partials/chirpbox-chat-public-display.php
  • 1× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function esc_html() in wp-content/plugins/chirpbox-chat/admin/partials/chirpbox-chat-admin-display.php:19

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)
No browser issues were found

Optimizations

Plugin configuration 97% 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
These attributes need your attention:
  • Plugin Name: Write the name of your plugin instead of "Plugin Name" on the first line ( === chirpbox-chat === )
The official readme.txt might help

chirpbox-chat/chirpbox-chat.php Passed 13 tests

The main PHP script in "Chirpbox Chat" version 1.2.2 is automatically included on every request by WordPress
64 characters long description:
Powerful and easy to use chat widget for any website - Chirpbox.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short check of programming languages and file extensions; no executable files are allowed
Good job! No executable or dangerous file extensions detected228 lines of code in 16 files:
LanguageFilesBlank linesComment linesLines of code
PHP12141559222
JavaScript24546
CSS2080

PHP code Passed 2 tests

This is a very shot review of cyclomatic complexity and code structure
This plugin has no cyclomatic complexity issues
Cyclomatic complexity
Average complexity per logical line of code0.09
Average class complexity1.71
▷ Minimum class complexity1.00
▷ Maximum class complexity4.00
Average method complexity1.17
▷ Minimum method complexity1.00
▷ Maximum method complexity4.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes7
▷ Abstract classes00.00%
▷ Concrete classes7100.00%
▷ Final classes00.00%
Methods30
▷ Static methods26.67%
▷ Public methods2583.33%
▷ Protected methods00.00%
▷ Private methods516.67%
Functions3
▷ Named functions3100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.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
No PNG files were detected