77% socialintents-slack-chat

Code Review | Slack Chat

WordPress plugin Slack Chat scored77%from 54 tests.

About plugin

  • Plugin page: socialintents-sla...
  • Plugin version: 1.2.7
  • PHP version: 7.4.16
  • WordPress compatibility: 3.6-5.2
  • WordPress version: 6.3.1
  • First release: Jan 11, 2018
  • Latest release: Jul 22, 2019
  • Number of updates: 482
  • Update frequency: every 4.3 days
  • Top authors: socialintents (100%)

Code review

54 tests

User reviews

2 reviews

Install metrics

200+ active /26,781 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
The plugin installed gracefully, with no errors

Server metrics [RAM: ▲0.02MB] [CPU: ▼4.40ms] Passed 4 tests

An overview of server-side resources used by Slack Chat
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.48 ▲0.0234.64 ▼10.71
Dashboard /wp-admin3.33 ▲0.0343.53 ▼4.41
Posts /wp-admin/edit.php3.38 ▲0.0246.87 ▼1.56
Add New Post /wp-admin/post-new.php5.91 ▲0.0294.70 ▲5.56
Media Library /wp-admin/upload.php3.25 ▲0.0234.34 ▼0.93
Slack Chat /wp-admin/options-general.php?page=slack-chat3.2232.09

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

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

Browser metrics Passed 4 tests

Slack Chat: an overview of browser usage
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,828 ▲5713.23 ▼1.141.70 ▼0.2240.98 ▲1.18
Dashboard /wp-admin2,234 ▲425.86 ▲0.90102.32 ▼2.5467.05 ▲24.87
Posts /wp-admin/edit.php2,127 ▲352.00 ▼0.0338.34 ▼1.3434.34 ▼3.98
Add New Post /wp-admin/post-new.php1,544 ▲223.32 ▲4.99699.19 ▲111.0755.58 ▲9.13
Media Library /wp-admin/upload.php1,420 ▲294.21 ▲0.0296.36 ▼1.6070.50 ▲27.51
Slack Chat /wp-admin/options-general.php?page=slack-chat9032.0225.0028.84

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
The following items require your attention
  • Zombie WordPress options detected upon uninstall: 6 options
    • widget_recent-comments
    • db_upgraded
    • widget_theysaidso_widget
    • widget_recent-posts
    • can_compress_scripts
    • theysaidso_admin_options

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Even though no errors were found, this is by no means an exhaustive test

SRP 0% 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
Please take a closer look at the following
  • 1× PHP files output text when accessed directly:
    • > /wp-content/plugins/socialintents-slack-chat/options.php
  • 1× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugins_url() in wp-content/plugins/socialintents-slack-chat/slack-chat.php:11

User-side errors Passed 1 test

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

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file is undoubtedly the most important file in your plugin, preparing it for public listing on WordPress.org
These attributes need your attention:
  • Screenshots: Add images for these screenshots: #1 (Slack Chat Visitor Popup), #2 (Slack Channel Example), #3 (Social Intents Overview)
Please take inspiration from this readme.txt

socialintents-slack-chat/slack-chat.php 85% from 13 tests

"Slack Chat" version 1.2.7's main PHP file describes plugin functionality and also serves as the entry point to any WordPress functionality
It is important to fix the following:
  • Main file name: Name the main plugin file the same as the plugin slug ("socialintents-slack-chat.php" instead of "slack-chat.php")
  • Description: Please keep the plugin description shorter than 140 characters (currently 215 characters long)

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
Everything looks great! No dangerous files found in this plugin118 lines of code in 2 files:
LanguageFilesBlank linesComment linesLines of code
PHP2228118

PHP code Passed 2 tests

Analyzing logical lines of code, cyclomatic complexity, and other code metrics
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity
Average complexity per logical line of code0.27
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%
Functions9
▷ Named functions9100.00%
▷ Anonymous functions00.00%
Constants2
▷ Global constants2100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size 50% from 2 tests

Image compression 50% from 2 tests

It is recommended to compress PNG files in your plugin to minimize bandwidth usage
5 PNG files occupy 3.50MB with 2.38MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
screenshot-2.png645.17KB180.34KB▼ 72.05%
screenshot-1.png657.52KB289.98KB▼ 55.90%
si-small.png3.71KB1.27KB▼ 65.90%
screenshot-3.png505.92KB111.14KB▼ 78.03%
screenshot-4.png1,767.56KB554.17KB▼ 68.65%