Skip to content
This repository has been archived by the owner on Sep 20, 2024. It is now read-only.

slack api - support of blocks #1594

Merged
merged 2 commits into from
Feb 21, 2019
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions lib/SlackBot.js
Original file line number Diff line number Diff line change
Expand Up @@ -573,6 +573,10 @@ function Slackbot(configuration) {
platform_message.link_names = message.link_names || null;
platform_message.attachments = message.attachments ?
JSON.stringify(message.attachments) : null;
if(message.blocks){
platform_message.blocks = JSON.stringify(message.blocks);
}

platform_message.unfurl_links = typeof message.unfurl_links !== 'undefined' ? message.unfurl_links : null;
platform_message.unfurl_media = typeof message.unfurl_media !== 'undefined' ? message.unfurl_media : null;
platform_message.icon_url = message.icon_url || null;
Expand Down