mirror of
https://github.com/advplyr/audiobookshelf.git
synced 2024-12-20 19:06:06 +01:00
Merge pull request #3107 from taxilian/bug/oldLibraryItemNull
bug: if oldLibraryItem is null things crash
This commit is contained in:
commit
599623570b
@ -176,9 +176,11 @@ class LibraryScanner {
|
||||
|
||||
// TODO: Temporary while using old model to socket emit
|
||||
const oldLibraryItem = await Database.libraryItemModel.getOldById(existingLibraryItem.id)
|
||||
oldLibraryItem.isMissing = true
|
||||
oldLibraryItem.updatedAt = Date.now()
|
||||
oldLibraryItemsUpdated.push(oldLibraryItem)
|
||||
if (oldLibraryItem) {
|
||||
oldLibraryItem.isMissing = true
|
||||
oldLibraryItem.updatedAt = Date.now()
|
||||
oldLibraryItemsUpdated.push(oldLibraryItem)
|
||||
}
|
||||
}
|
||||
}
|
||||
} else {
|
||||
|
Loading…
Reference in New Issue
Block a user