mirror of
https://github.com/advplyr/audiobookshelf-app.git
synced 2025-08-03 17:44:51 +02:00
Fix crashes related to Realm threading
This commit is contained in:
parent
8ce0d9ce56
commit
b0905d0270
8 changed files with 236 additions and 75 deletions
|
@ -197,4 +197,9 @@ class Database {
|
|||
realm.delete(progress!)
|
||||
}
|
||||
}
|
||||
|
||||
public func getPlaybackSession(id: String) -> PlaybackSession? {
|
||||
let realm = try! Realm()
|
||||
return realm.object(ofType: PlaybackSession.self, forPrimaryKey: id)
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue