Fixed: Don't accidentally remove book editions when refreshing a book

pull/965/head
ta264 4 years ago
parent 8ec13f5ead
commit 8bc44f2a29

@ -87,6 +87,13 @@ namespace NzbDrone.Core.Books
newbook.AuthorMetadataId = book.AuthorMetadataId;
newbook.AuthorMetadata.Value.Id = book.AuthorMetadataId;
// make sure to grab editions data for any other existing editions
foreach (var edition in book.Editions.Value.Skip(1))
{
tuple = _bookInfo.GetBookInfo(edition.ForeignEditionId, false);
newbook.Editions.Value.AddRange(tuple.Item2.Editions.Value);
}
author.Books = new List<Book> { newbook };
return author;
}

Loading…
Cancel
Save