set user.current by value from userAttributes

this should have no effect but it should ensure "current" is not falsely set to true if the method storeProfile will be used for more scenarios in the future.

Signed-off-by: Marcel Hibbe <dev@mhibbe.de>
This commit is contained in:
Marcel Hibbe 2022-11-18 15:01:43 +01:00 committed by Andy Scherzinger
parent d4e545e67d
commit e9dbcc554a
No known key found for this signature in database
GPG key ID: 6CADC7E3523C308B

View file

@ -149,7 +149,7 @@ class UserManager internal constructor(private val userRepository: UsersReposito
else -> { else -> {
user.token = userAttributes.token user.token = userAttributes.token
user.baseUrl = userAttributes.serverUrl user.baseUrl = userAttributes.serverUrl
user.current = true user.current = userAttributes.currentUser
user.userId = userAttributes.userId user.userId = userAttributes.userId
user.token = userAttributes.token user.token = userAttributes.token
user.displayName = userAttributes.displayName user.displayName = userAttributes.displayName
@ -237,7 +237,7 @@ class UserManager internal constructor(private val userRepository: UsersReposito
data class UserAttributes( data class UserAttributes(
val id: Long?, val id: Long?,
val serverUrl: String?, val serverUrl: String?,
val currentUser: Boolean?, val currentUser: Boolean,
val userId: String?, val userId: String?,
val token: String?, val token: String?,
val displayName: String?, val displayName: String?,