fix: iOS chapter sleep timer issues

This commit is contained in:
ronaldheft 2022-09-18 14:21:41 -04:00
parent 4e94fd6ad0
commit 5d23c17d30
No known key found for this signature in database
3 changed files with 18 additions and 18 deletions

View file

@ -244,6 +244,7 @@ class Database {
public func getPlaybackSession(id: String) -> PlaybackSession? {
do {
let realm = try Realm()
realm.refresh() // Refresh, because working with stale sessions leads to wrong times
return realm.object(ofType: PlaybackSession.self, forPrimaryKey: id)
} catch {
debugPrint(error)