From 7a751b8f91df5d94de1b04b5a538940dbdd2d4a9 Mon Sep 17 00:00:00 2001 From: yuuzhan Date: Thu, 2 Feb 2023 12:46:22 -0500 Subject: [PATCH] Updated function parseAndCheckForUpdates to pass Library Item rather then just the metadata object --- server/objects/mediaTypes/Book.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/server/objects/mediaTypes/Book.js b/server/objects/mediaTypes/Book.js index bc34bbb8..321d0170 100644 --- a/server/objects/mediaTypes/Book.js +++ b/server/objects/mediaTypes/Book.js @@ -252,7 +252,7 @@ class Book { if (metadataAbs) { Logger.debug(`[Book] Found metadata.abs file for "${this.metadata.title}"`) const metadataText = await readTextFile(metadataAbs.metadata.path) - const abmetadataUpdates = abmetadataGenerator.parseAndCheckForUpdates(metadataText, this.metadata, 'book') + const abmetadataUpdates = abmetadataGenerator.parseAndCheckForUpdates(metadataText, this, 'book') if (abmetadataUpdates && Object.keys(abmetadataUpdates).length) { Logger.debug(`[Book] "${this.metadata.title}" changes found in metadata.abs file`, abmetadataUpdates) metadataUpdatePayload = { @@ -489,4 +489,4 @@ class Book { return this.metadata.authorName } } -module.exports = Book \ No newline at end of file +module.exports = Book