mirror of
https://github.com/advplyr/audiobookshelf-app.git
synced 2026-08-30 15:17:14 +02:00
Handle deleting library items
This commit is contained in:
@@ -81,7 +81,7 @@ public class AbsDatabase: CAPPlugin {
|
||||
|
||||
@objc func getLocalLibraryItem(_ call: CAPPluginCall) {
|
||||
do {
|
||||
let item = Database.shared.getLocalLibraryItem(localLibraryItem: call.getString("id") ?? "")
|
||||
let item = Database.shared.getLocalLibraryItem(localLibraryItemId: call.getString("id") ?? "")
|
||||
switch item {
|
||||
case .some(let foundItem):
|
||||
call.resolve(try foundItem.asDictionary())
|
||||
@@ -97,7 +97,7 @@ public class AbsDatabase: CAPPlugin {
|
||||
|
||||
@objc func getLocalLibraryItemByLId(_ call: CAPPluginCall) {
|
||||
do {
|
||||
let item = Database.shared.getLocalLibraryItemByLLId(libraryItem: call.getString("libraryItemId") ?? "")
|
||||
let item = Database.shared.getLocalLibraryItem(byServerLibraryItemId: call.getString("libraryItemId") ?? "")
|
||||
switch item {
|
||||
case .some(let foundItem):
|
||||
call.resolve(try foundItem.asDictionary())
|
||||
|
||||
Reference in New Issue
Block a user