78% captivate-chat

Code Review | Captivate Chat

WordPress plugin Captivate Chat scored78%from 54 tests.

About plugin

  • Plugin page: captivate-chat
  • Plugin version: 0.0.4
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0-6.1.1
  • WordPress version: 6.3.1
  • First release: Apr 10, 2023
  • Latest release: Apr 28, 2023
  • Number of updates: 4
  • Update frequency: every 6.0 days
  • Top authors: ebvjrwork (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /184 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▲0.01MB] [CPU: ▼9.59ms] Passed 4 tests

Analyzing server-side resources used by Captivate Chat
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.48 ▲0.0238.54 ▼2.48
Dashboard /wp-admin3.33 ▼0.0248.29 ▼10.57
Posts /wp-admin/edit.php3.38 ▲0.0249.88 ▼0.06
Add New Post /wp-admin/post-new.php5.91 ▲0.0280.90 ▼20.29
Media Library /wp-admin/upload.php3.25 ▲0.0231.85 ▼5.03
Captivate Chat /wp-admin/options-general.php?page=captivatechat3.2129.69

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

How much does this plugin use your filesystem and database?
There were no storage issued detected upon installing this plugin
Filesystem: 6 new files
Database: no new tables, 7 new options
New WordPress options
widget_theysaidso_widget
captivate_widget_api_key
widget_recent-comments
theysaidso_admin_options
widget_recent-posts
can_compress_scripts
db_upgraded

Browser metrics Passed 4 tests

A check of browser resources used by Captivate Chat
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,843 ▲9713.20 ▼1.181.69 ▼0.0642.53 ▼3.98
Dashboard /wp-admin2,249 ▲615.81 ▼0.12102.43 ▼10.5540.30 ▼8.67
Posts /wp-admin/edit.php2,090 ▼22.03 ▼0.0135.72 ▼6.1632.03 ▼0.95
Add New Post /wp-admin/post-new.php1,536 ▼623.07 ▲4.77643.16 ▲18.9063.93 ▲1.28
Media Library /wp-admin/upload.php1,389 ▲14.21 ▲0.02101.14 ▲2.9341.52 ▼3.97
Captivate Chat /wp-admin/options-general.php?page=captivatechat1,3799.25291.0970.78

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
  • Zombie WordPress options were found after uninstall: 7 options
    • can_compress_scripts
    • widget_recent-posts
    • captivate_widget_api_key
    • db_upgraded
    • widget_recent-comments
    • theysaidso_admin_options
    • widget_theysaidso_widget

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
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 fix the following
  • 1× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/captivate-chat/captivatechat.php:28

User-side errors 0% from 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
There are user-side issues you should fix
    • > GET request to /wp-admin/options-general.php?page=captivatechat
    • > Other (warning) in unknown
    /wp-admin/options-general.php?page=captivatechat 142 Unrecognized feature: 'web-share'.

Optimizations

Plugin configuration 96% 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
4 plugin tags: chat, captivaate, social, widget

captivate-chat/captivatechat.php 92% from 13 tests

The entry point to "Captivate Chat" version 0.0.4 is a PHP file that has certain tags in its header comment area
It is important to fix the following:
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("captivate-chat.php" instead of "captivatechat.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are not allowed as they can serve as attack vectors
Everything looks great! No dangerous files found in this plugin76 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code
PHP1183376

PHP code Passed 2 tests

Analyzing logical lines of code, cyclomatic complexity, and other code metrics
All good! No complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.09
Average class complexity0.00
▷ Minimum class complexity0.00
▷ Maximum class complexity0.00
Average method complexity0.00
▷ Minimum method complexity0.00
▷ Maximum method complexity0.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes0
▷ Abstract classes00.00%
▷ Concrete classes00.00%
▷ Final classes00.00%
Methods0
▷ Static methods00.00%
▷ Public methods00.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions8
▷ Named functions8100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
3 PNG files occupy 0.05MB with 0.03MB in potential savings
Potential savings
Compression of 3 random PNG files using pngquant
FileSize - originalSize - compressedSavings
img/captivate-logo.png8.22KB3.26KB▼ 60.39%
img/captivate.png3.58KB1.95KB▼ 45.54%
img/api.png37.85KB17.68KB▼ 53.29%