mirror of
https://github.com/cwinfo/matterbridge.git
synced 2024-11-22 16:20:26 +00:00
Add Title from attachment slack message (#446)
This commit is contained in:
parent
bd9ea7a88d
commit
594492fbdd
@ -503,7 +503,10 @@ func (b *Bslack) handleMessageEvent(ev *slack.MessageEvent) (*config.Message, er
|
|||||||
if rmsg.Text == "" {
|
if rmsg.Text == "" {
|
||||||
for _, attach := range ev.Attachments {
|
for _, attach := range ev.Attachments {
|
||||||
if attach.Text != "" {
|
if attach.Text != "" {
|
||||||
rmsg.Text = attach.Text
|
if attach.Title != "" {
|
||||||
|
rmsg.Text = attach.Title + "\n"
|
||||||
|
}
|
||||||
|
rmsg.Text += attach.Text
|
||||||
} else {
|
} else {
|
||||||
rmsg.Text = attach.Fallback
|
rmsg.Text = attach.Fallback
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user