10% notify-slack-bot

Code Review | Notify Slack Bot

WordPress plugin Notify Slack Bot scored10%from 54 tests.

About plugin

  • Plugin page: notify-slack-bot
  • Plugin version: 1.0.0
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.7-6.2
  • WordPress version: 6.3.1
  • First release: Apr 19, 2023
  • Latest release: Apr 19, 2023
  • Number of updates: 4
  • Update frequency: every 112.0 days
  • Top authors: chigozieorunta (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /111 total downloads

Benchmarks

Plugin footprint 40% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
It is recommended to fix the following installer errors
  • The plugin cannot be installed
    • > User error in wp-content/plugins/notify-slack-bot/vendor/composer/platform_check.php+24
    Composer detected issues in your platform: Your Composer dependencies require a PHP version ">= 8.0.2". You are running 7.4.16.

Server metrics [RAM: ▼1.93MB] [CPU: ▼59.18ms] Passed 4 tests

This is a short check of server-side resources used by Notify Slack Bot
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /2.05 ▼1.417.95 ▼37.75
Dashboard /wp-admin2.07 ▼1.236.75 ▼49.00
Posts /wp-admin/edit.php2.08 ▼1.286.25 ▼44.85
Add New Post /wp-admin/post-new.php2.07 ▼3.815.33 ▼105.10
Media Library /wp-admin/upload.php2.08 ▼1.155.88 ▼32.57

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

Input-output and database impact of this plugin
This plugin was installed successfully
Filesystem: 789 new files
Database: no new tables, no new options

Browser metrics Passed 4 tests

Checking browser requirements for Notify Slack Bot
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,963 ▲20218.51 ▲4.161.97 ▼0.0145.89 ▼0.30
Dashboard /wp-admin2,376 ▲1999.04 ▲3.37212.64 ▲112.0740.86 ▼2.41
Posts /wp-admin/edit.php2,310 ▲2106.24 ▲4.2783.54 ▲44.1232.09 ▼2.58
Add New Post /wp-admin/post-new.php1,593 ▲6025.50 ▲2.49730.46 ▲26.5750.39 ▼0.93
Media Library /wp-admin/upload.php1,447 ▲506.65 ▲2.47113.56 ▲2.2540.13 ▼9.62

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
Please fix the following items
  • The plugin did not uninstall gracefully
    • > User error in wp-content/plugins/notify-slack-bot/vendor/composer/platform_check.php+24
    Composer detected issues in your platform: Your Composer dependencies require a PHP version ">= 8.0.2". You are running 7.4.16.
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • widget_recent-posts
    • can_compress_scripts
    • widget_recent-comments
    • db_upgraded
    • theysaidso_admin_options
    • widget_theysaidso_widget

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
The smoke test was a success, however most plugin functionality was not tested

SRP 0% 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 perform the action of outputting non-empty strings when accessed directly:
    • > /wp-content/plugins/notify-slack-bot/vendor/htmlburger/carbon-fields/templates/Exception/incorrect-syntax.php
  • 319× GET requests to PHP files have triggered server-side errors or warnings (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Class 'Maknz\\Slack\\BlockElement\\AbstractStaticSelect' not found in wp-content/plugins/notify-slack-bot/vendor/alek13/slack/src/BlockElement/MultiStaticSelect.php:7
    • > PHP Fatal error
      Uncaught Error: Class 'Carbon_Fields\\Datastore\\Meta_Datastore' not found in wp-content/plugins/notify-slack-bot/vendor/htmlburger/carbon-fields/core/Datastore/User_Meta_Datastore.php:10
    • > PHP Fatal error
      Composer detected issues in your platform: Your Composer dependencies require a PHP version ">= 8.0.2". You are running 7.4.16. in wp-content/plugins/notify-slack-bot/vendor/composer/platform_check.php on line 24
    • > PHP Fatal error
      Uncaught Error: Using $this when not in object context in wp-content/plugins/notify-slack-bot/vendor/htmlburger/carbon-fields/templates/Container/common/options-page.php:2
    • > PHP Fatal error
      Uncaught Error: Interface 'Carbon_Fields\\Container\\Fulfillable\\Fulfillable' not found in wp-content/plugins/notify-slack-bot/vendor/htmlburger/carbon-fields/core/Container/Fulfillable/Fulfillable_Collection.php:9
    • > PHP Fatal error
      Uncaught Error: Class 'Composer\\Installers\\BaseInstaller' not found in wp-content/plugins/notify-slack-bot/vendor/composer/installers/src/Composer/Installers/PimcoreInstaller.php:4
    • > PHP Fatal error
      Uncaught Error: Class 'Composer\\Installers\\BaseInstaller' not found in wp-content/plugins/notify-slack-bot/vendor/composer/installers/src/Composer/Installers/SMFInstaller.php:4
    • > PHP Fatal error
      Uncaught Error: Class 'Maknz\\Slack\\BlockElement\\MultiDynamicSelect' not found in wp-content/plugins/notify-slack-bot/vendor/alek13/slack/src/BlockElement/MultiExternalSelect.php:7
    • > PHP Fatal error
      Uncaught Error: Class 'Maknz\\Slack\\Block\\ElementsBlock' not found in wp-content/plugins/notify-slack-bot/vendor/alek13/slack/src/Block/Context.php:4
    • > PHP Fatal error
      Uncaught Error: Class 'Composer\\Installers\\BaseInstaller' not found in wp-content/plugins/notify-slack-bot/vendor/composer/installers/src/Composer/Installers/OxidInstaller.php:6

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
Everything seems fine on the user side

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

Don't ignore readme.txt as it is the file that instructs WordPress.org on how to present your plugin to the world
2 plugin tags: slack, bot

notify-slack-bot/notify-slack-bot.php 92% from 13 tests

The entry point to "Notify Slack Bot" version 1.0.0 is a PHP file that has certain tags in its header comment area
It is important to fix the following:
  • Text Domain: If you choose to specify the text domain, it must be the same as the plugin slug; optional since WordPress version 4.6

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short glimpse at programming languages used with this plugin and a check that no dangerous files are present
No dangerous file extensions were detected52,824 lines of code in 725 files:
LanguageFilesBlank linesComment linesLines of code
PHP4275,87816,16323,875
JavaScript1747,09910,93016,200
Markdown231,48204,328
PO File298981,1112,425
CSS72401,1572,221
Sass4936531,868
JSON13001,784
YAML3313123

PHP code Passed 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
This plugin has no cyclomatic complexity problems
Cyclomatic complexity
Average complexity per logical line of code0.33
Average class complexity7.28
▷ Minimum class complexity1.00
▷ Maximum class complexity88.00
Average method complexity2.16
▷ Minimum method complexity1.00
▷ Maximum method complexity26.00
Code structure
Namespaces39
Interfaces32
Traits9
Classes358
▷ Abstract classes256.98%
▷ Concrete classes33393.02%
▷ Final classes3711.11%
Methods2,102
▷ Static methods24111.47%
▷ Public methods1,75983.68%
▷ Protected methods21510.23%
▷ Private methods1286.09%
Functions234
▷ Named functions5322.65%
▷ Anonymous functions18177.35%
Constants108
▷ Global constants54.63%
▷ Class constants10395.37%
▷ Public constants9289.32%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
No PNG images were found in this plugin