Skip to content

Commit

Permalink
Update naming: mutableAccessTokenFlow -> mutableAuthStateFlow (#56)
Browse files Browse the repository at this point in the history
  • Loading branch information
ahaisting-livefront authored and vvolkgang committed Jun 20, 2024
1 parent 747dbdb commit 3de916c
Showing 1 changed file with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,8 @@ class AuthRepositoryImpl @Inject constructor(
private val bitwardenSdkClient: Client,
) : AuthRepository {

private val mutableAccessTokenFlow = MutableStateFlow<AuthState>(AuthState.Unauthenticated)
override val authStateFlow: StateFlow<AuthState> = mutableAccessTokenFlow.asStateFlow()
private val mutableAuthStateFlow = MutableStateFlow<AuthState>(AuthState.Unauthenticated)
override val authStateFlow: StateFlow<AuthState> = mutableAuthStateFlow.asStateFlow()

/**
* Attempt to login with the given email.
Expand Down Expand Up @@ -55,7 +55,7 @@ class AuthRepositoryImpl @Inject constructor(
LoginResult.Error
},
onSuccess = {
mutableAccessTokenFlow.value = AuthState.Authenticated(it.accessToken)
mutableAuthStateFlow.value = AuthState.Authenticated(it.accessToken)
LoginResult.Success
},
)
Expand Down

0 comments on commit 3de916c

Please sign in to comment.