From dcc2a14c602e0d29d02c37dd2adbf4f80cad3da5 Mon Sep 17 00:00:00 2001 From: Qstick Date: Sat, 25 Feb 2023 13:08:13 -0600 Subject: [PATCH] Only send monitored edition in webhook payload. --- src/NzbDrone.Core/Notifications/Webhook/WebhookBook.cs | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/NzbDrone.Core/Notifications/Webhook/WebhookBook.cs b/src/NzbDrone.Core/Notifications/Webhook/WebhookBook.cs index fb9f1b869..cb514c5ed 100644 --- a/src/NzbDrone.Core/Notifications/Webhook/WebhookBook.cs +++ b/src/NzbDrone.Core/Notifications/Webhook/WebhookBook.cs @@ -9,7 +9,6 @@ public class WebhookBook { public WebhookBook() { - Editions = new List(); } public WebhookBook(Book book) @@ -18,13 +17,13 @@ public WebhookBook(Book book) GoodreadsId = book.ForeignBookId; Title = book.Title; ReleaseDate = book.ReleaseDate; - Editions = book.Editions.Value.Select(x => new WebhookBookEdition(x)).ToList(); + Edition = new WebhookBookEdition(book.Editions.Value.Single(e => e.Monitored)); } public int Id { get; set; } public string GoodreadsId { get; set; } public string Title { get; set; } - public List Editions { get; set; } + public WebhookBookEdition Edition { get; set; } public DateTime? ReleaseDate { get; set; } } }