5
0
mirror of https://github.com/cwinfo/matterbridge.git synced 2024-12-24 18:25:40 +00:00

Fix #1049: missing space before embeds (discord) (#1124)

This commit is contained in:
Qais Patankar 2020-05-06 23:19:48 +01:00 committed by GitHub
parent 2d8f749e36
commit 52a071e34d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 6 additions and 6 deletions

View File

@ -217,7 +217,7 @@ func handleEmbed(embed *discordgo.MessageEmbed) string {
i++
if i == 1 {
result += "embed: " + e
result += " embed: " + e
continue
}

View File

@ -20,14 +20,14 @@ func TestHandleEmbed(t *testing.T) {
embed: &discordgo.MessageEmbed{
Title: "blah",
},
result: "embed: blah\n",
result: " embed: blah\n",
},
"two": {
embed: &discordgo.MessageEmbed{
Title: "blah",
Description: "blah2",
},
result: "embed: blah - blah2\n",
result: " embed: blah - blah2\n",
},
"three": {
embed: &discordgo.MessageEmbed{
@ -35,20 +35,20 @@ func TestHandleEmbed(t *testing.T) {
Description: "blah2",
URL: "blah3",
},
result: "embed: blah - blah2 - blah3\n",
result: " embed: blah - blah2 - blah3\n",
},
"twob": {
embed: &discordgo.MessageEmbed{
Description: "blah2",
URL: "blah3",
},
result: "embed: blah2 - blah3\n",
result: " embed: blah2 - blah3\n",
},
"oneb": {
embed: &discordgo.MessageEmbed{
URL: "blah3",
},
result: "embed: blah3\n",
result: " embed: blah3\n",
},
}