summaryrefslogtreecommitdiffstats
path: root/bridge/discord
diff options
context:
space:
mode:
authorValdikSS <iam@valdikss.org.ru>2018-04-18 00:52:48 +0300
committerWim <wim@42.be>2018-04-17 23:52:48 +0200
commita12a8d4fe2d2f38074278396870085684f9548ca (patch)
tree199b2aa41a1ae544ddd36f727fe37cacf0e29699 /bridge/discord
parente57f3a7e6c9435cba74109fffd402216fcb80fe6 (diff)
downloadmatterbridge-msglm-a12a8d4fe2d2f38074278396870085684f9548ca.tar.gz
matterbridge-msglm-a12a8d4fe2d2f38074278396870085684f9548ca.tar.bz2
matterbridge-msglm-a12a8d4fe2d2f38074278396870085684f9548ca.zip
Send mediaserver link to Discord in Webhook mode (discord) (#405)
Diffstat (limited to 'bridge/discord')
-rw-r--r--bridge/discord/discord.go6
1 files changed, 6 insertions, 0 deletions
diff --git a/bridge/discord/discord.go b/bridge/discord/discord.go
index fa879d00..ef4e5ca6 100644
--- a/bridge/discord/discord.go
+++ b/bridge/discord/discord.go
@@ -130,6 +130,12 @@ func (b *Bdiscord) Send(msg config.Message) (string, error) {
return "", nil
}
b.Log.Debugf("Broadcasting using Webhook")
+ for _, f := range msg.Extra["file"] {
+ fi := f.(config.FileInfo)
+ if fi.URL != "" {
+ msg.Text += fi.URL + " "
+ }
+ }
err := b.c.WebhookExecute(
wID,
wToken,