diff options
| author | David Göransson <david.goransson90@gmail.com> | 2023-10-23 09:34:52 +0200 |
|---|---|---|
| committer | Jonatan Rhodin <jonatan.rhodin@mullvad.net> | 2023-10-25 15:17:22 +0200 |
| commit | dda6f7a8b287f388cce01d242f132ad763491368 (patch) | |
| tree | ff8dba60ad5d4b85fe04eac9b3617550c3126983 /android/app/src | |
| parent | 78ed10bb270c915157f8ca3e8bbb9fd1f381a8b3 (diff) | |
| download | mullvadvpn-dda6f7a8b287f388cce01d242f132ad763491368.tar.xz mullvadvpn-dda6f7a8b287f388cce01d242f132ad763491368.zip | |
Fix incorrect days on time left
Diffstat (limited to 'android/app/src')
| -rw-r--r-- | android/app/src/main/kotlin/net/mullvad/mullvadvpn/repository/AccountRepository.kt | 12 |
1 files changed, 2 insertions, 10 deletions
diff --git a/android/app/src/main/kotlin/net/mullvad/mullvadvpn/repository/AccountRepository.kt b/android/app/src/main/kotlin/net/mullvad/mullvadvpn/repository/AccountRepository.kt index 0bf8b1b8ec..782029dc78 100644 --- a/android/app/src/main/kotlin/net/mullvad/mullvadvpn/repository/AccountRepository.kt +++ b/android/app/src/main/kotlin/net/mullvad/mullvadvpn/repository/AccountRepository.kt @@ -45,22 +45,14 @@ class AccountRepository( messageHandler .events<Event.AccountExpiryEvent>() .map { it.expiry } - .stateIn( - CoroutineScope(dispatcher), - SharingStarted.WhileSubscribed(), - AccountExpiry.Missing - ) + .stateIn(CoroutineScope(dispatcher), SharingStarted.Eagerly, AccountExpiry.Missing) val accountHistory: StateFlow<AccountHistory> = messageHandler .events<Event.AccountHistoryEvent>() .map { it.history } .onStart { fetchAccountHistory() } - .stateIn( - CoroutineScope(dispatcher), - SharingStarted.WhileSubscribed(), - AccountHistory.Missing - ) + .stateIn(CoroutineScope(dispatcher), SharingStarted.Eagerly, AccountHistory.Missing) private val loginEvents: SharedFlow<LoginResult> = messageHandler |
