|
|
|
@ -26,7 +26,7 @@ namespace NzbDrone.Core.Notifications.Discord
|
|
|
|
|
{
|
|
|
|
|
var embeds = new List<Embed>
|
|
|
|
|
{
|
|
|
|
|
new Embed
|
|
|
|
|
new ()
|
|
|
|
|
{
|
|
|
|
|
Description = message.Message,
|
|
|
|
|
Title = message.Author.Name,
|
|
|
|
@ -43,7 +43,7 @@ namespace NzbDrone.Core.Notifications.Discord
|
|
|
|
|
{
|
|
|
|
|
var attachments = new List<Embed>
|
|
|
|
|
{
|
|
|
|
|
new Embed
|
|
|
|
|
new ()
|
|
|
|
|
{
|
|
|
|
|
Description = message.Message,
|
|
|
|
|
Title = message.Author.Name,
|
|
|
|
@ -60,7 +60,7 @@ namespace NzbDrone.Core.Notifications.Discord
|
|
|
|
|
{
|
|
|
|
|
var attachments = new List<Embed>
|
|
|
|
|
{
|
|
|
|
|
new Embed
|
|
|
|
|
new ()
|
|
|
|
|
{
|
|
|
|
|
Title = author.Name,
|
|
|
|
|
}
|
|
|
|
@ -75,12 +75,12 @@ namespace NzbDrone.Core.Notifications.Discord
|
|
|
|
|
{
|
|
|
|
|
var attachments = new List<Embed>
|
|
|
|
|
{
|
|
|
|
|
new Embed
|
|
|
|
|
new ()
|
|
|
|
|
{
|
|
|
|
|
Title = author.Name,
|
|
|
|
|
Fields = new List<DiscordField>()
|
|
|
|
|
{
|
|
|
|
|
new DiscordField()
|
|
|
|
|
new ()
|
|
|
|
|
{
|
|
|
|
|
Name = "Links",
|
|
|
|
|
Value = string.Join(" / ", author.Metadata.Value.Links.Select(link => $"[{link.Name}]({link.Url})"))
|
|
|
|
@ -88,7 +88,7 @@ namespace NzbDrone.Core.Notifications.Discord
|
|
|
|
|
},
|
|
|
|
|
}
|
|
|
|
|
};
|
|
|
|
|
var payload = CreatePayload($"Author Added", attachments);
|
|
|
|
|
var payload = CreatePayload("Author Added", attachments);
|
|
|
|
|
|
|
|
|
|
_proxy.SendPayload(payload, Settings);
|
|
|
|
|
}
|
|
|
|
@ -97,7 +97,7 @@ namespace NzbDrone.Core.Notifications.Discord
|
|
|
|
|
{
|
|
|
|
|
var attachments = new List<Embed>
|
|
|
|
|
{
|
|
|
|
|
new Embed
|
|
|
|
|
new ()
|
|
|
|
|
{
|
|
|
|
|
Title = deleteMessage.Author.Name,
|
|
|
|
|
Description = deleteMessage.DeletedFilesMessage
|
|
|
|
@ -113,9 +113,9 @@ namespace NzbDrone.Core.Notifications.Discord
|
|
|
|
|
{
|
|
|
|
|
var attachments = new List<Embed>
|
|
|
|
|
{
|
|
|
|
|
new Embed
|
|
|
|
|
new ()
|
|
|
|
|
{
|
|
|
|
|
Title = $"${deleteMessage.Book.Author.Value.Name} - ${deleteMessage.Book.Title}",
|
|
|
|
|
Title = $"{deleteMessage.Book.Author.Value.Name} - ${deleteMessage.Book.Title}",
|
|
|
|
|
Description = deleteMessage.DeletedFilesMessage
|
|
|
|
|
}
|
|
|
|
|
};
|
|
|
|
@ -129,9 +129,9 @@ namespace NzbDrone.Core.Notifications.Discord
|
|
|
|
|
{
|
|
|
|
|
var attachments = new List<Embed>
|
|
|
|
|
{
|
|
|
|
|
new Embed
|
|
|
|
|
new ()
|
|
|
|
|
{
|
|
|
|
|
Title = $"${deleteMessage.Book.Author.Value.Name} - ${deleteMessage.Book.Title} - file deleted",
|
|
|
|
|
Title = $"{deleteMessage.Book.Author.Value.Name} - ${deleteMessage.Book.Title} - file deleted",
|
|
|
|
|
Description = deleteMessage.BookFile.Path
|
|
|
|
|
}
|
|
|
|
|
};
|
|
|
|
@ -145,7 +145,7 @@ namespace NzbDrone.Core.Notifications.Discord
|
|
|
|
|
{
|
|
|
|
|
var attachments = new List<Embed>
|
|
|
|
|
{
|
|
|
|
|
new Embed
|
|
|
|
|
new ()
|
|
|
|
|
{
|
|
|
|
|
Title = healthCheck.Source.Name,
|
|
|
|
|
Text = healthCheck.Message,
|
|
|
|
@ -162,7 +162,7 @@ namespace NzbDrone.Core.Notifications.Discord
|
|
|
|
|
{
|
|
|
|
|
var attachments = new List<Embed>
|
|
|
|
|
{
|
|
|
|
|
new Embed
|
|
|
|
|
new ()
|
|
|
|
|
{
|
|
|
|
|
Title = BOOK_RETAGGED_TITLE,
|
|
|
|
|
Text = message.Message
|
|
|
|
@ -178,7 +178,7 @@ namespace NzbDrone.Core.Notifications.Discord
|
|
|
|
|
{
|
|
|
|
|
var attachments = new List<Embed>
|
|
|
|
|
{
|
|
|
|
|
new Embed
|
|
|
|
|
new ()
|
|
|
|
|
{
|
|
|
|
|
Description = message.Message,
|
|
|
|
|
Title = message.SourceTitle,
|
|
|
|
@ -195,7 +195,7 @@ namespace NzbDrone.Core.Notifications.Discord
|
|
|
|
|
{
|
|
|
|
|
var attachments = new List<Embed>
|
|
|
|
|
{
|
|
|
|
|
new Embed
|
|
|
|
|
new ()
|
|
|
|
|
{
|
|
|
|
|
Description = message.Message,
|
|
|
|
|
Title = message.Book?.Title ?? message.Message,
|
|
|
|
@ -212,7 +212,7 @@ namespace NzbDrone.Core.Notifications.Discord
|
|
|
|
|
{
|
|
|
|
|
var attachments = new List<Embed>
|
|
|
|
|
{
|
|
|
|
|
new Embed
|
|
|
|
|
new ()
|
|
|
|
|
{
|
|
|
|
|
Author = new DiscordAuthor
|
|
|
|
|
{
|
|
|
|
@ -224,12 +224,12 @@ namespace NzbDrone.Core.Notifications.Discord
|
|
|
|
|
Color = (int)DiscordColors.Standard,
|
|
|
|
|
Fields = new List<DiscordField>()
|
|
|
|
|
{
|
|
|
|
|
new DiscordField()
|
|
|
|
|
new ()
|
|
|
|
|
{
|
|
|
|
|
Name = "Previous Version",
|
|
|
|
|
Value = updateMessage.PreviousVersion.ToString()
|
|
|
|
|
},
|
|
|
|
|
new DiscordField()
|
|
|
|
|
new ()
|
|
|
|
|
{
|
|
|
|
|
Name = "New Version",
|
|
|
|
|
Value = updateMessage.NewVersion.ToString()
|
|
|
|
|