Add a db query to get all the Sessions.

This commit is contained in:
Benoit Marty 2023-03-29 15:40:34 +02:00 committed by Benoit Marty
parent 2135d75712
commit 70de1bd6a0
5 changed files with 16 additions and 1 deletions

View file

@ -38,6 +38,10 @@ class InMemorySessionStore : SessionStore {
return sessionDataFlow.value.takeIf { it?.userId == sessionId }
}
override suspend fun getAllSessions(): List<SessionData> {
return listOfNotNull(sessionDataFlow.value)
}
override suspend fun getLatestSession(): SessionData? {
return sessionDataFlow.value
}