From 06bff064a8179a6df2fd8d51d8668d28771a785f Mon Sep 17 00:00:00 2001 From: Adam Brown Date: Sun, 6 Nov 2022 20:49:15 +0000 Subject: [PATCH] fixing app upgrade not asking user to clear cache --- .../kotlin/app/dapk/st/home/BetaVersionUpgradeUseCase.kt | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/features/home/src/main/kotlin/app/dapk/st/home/BetaVersionUpgradeUseCase.kt b/features/home/src/main/kotlin/app/dapk/st/home/BetaVersionUpgradeUseCase.kt index 4a1168a..565e810 100644 --- a/features/home/src/main/kotlin/app/dapk/st/home/BetaVersionUpgradeUseCase.kt +++ b/features/home/src/main/kotlin/app/dapk/st/home/BetaVersionUpgradeUseCase.kt @@ -25,8 +25,6 @@ class BetaVersionUpgradeUseCase( return when (previousVersion) { null -> false else -> currentVersion > previousVersion - }.also { - applicationPreferences.setVersion(ApplicationVersion(currentVersion)) } } @@ -38,7 +36,8 @@ class BetaVersionUpgradeUseCase( } } - fun notifyUpgraded() { + suspend fun notifyUpgraded() { + applicationPreferences.setVersion(ApplicationVersion(buildMeta.versionCode)) _continuation?.resume(Unit) _continuation = null }