diff --git a/app/src/main/kotlin/com/wire/android/ui/home/messagecomposer/SelfDeletionDuration.kt b/app/src/main/kotlin/com/wire/android/ui/home/messagecomposer/SelfDeletionDuration.kt index d483a36aad5..1d79f63202e 100644 --- a/app/src/main/kotlin/com/wire/android/ui/home/messagecomposer/SelfDeletionDuration.kt +++ b/app/src/main/kotlin/com/wire/android/ui/home/messagecomposer/SelfDeletionDuration.kt @@ -21,15 +21,14 @@ import com.wire.android.BuildConfig import com.wire.android.R import com.wire.android.util.ui.UIText import kotlin.time.Duration -import kotlin.time.Duration.Companion.ZERO import kotlin.time.Duration.Companion.days import kotlin.time.Duration.Companion.hours import kotlin.time.Duration.Companion.minutes import kotlin.time.Duration.Companion.seconds @Suppress("MagicNumber") -enum class SelfDeletionDuration(val value: Duration, val longLabel: UIText, val shortLabel: UIText) { - None(ZERO, UIText.StringResource(R.string.label_off), UIText.StringResource(R.string.label_off)), +enum class SelfDeletionDuration(val value: Duration?, val longLabel: UIText, val shortLabel: UIText) { + None(null, UIText.StringResource(R.string.label_off), UIText.StringResource(R.string.label_off)), TenSeconds( 10.seconds, UIText.PluralResource(R.plurals.seconds_long_label, 10, 10), diff --git a/app/src/main/kotlin/com/wire/android/ui/sharing/ImportMediaAuthenticatedViewModel.kt b/app/src/main/kotlin/com/wire/android/ui/sharing/ImportMediaAuthenticatedViewModel.kt index bbe021f761a..c3a301dc1fa 100644 --- a/app/src/main/kotlin/com/wire/android/ui/sharing/ImportMediaAuthenticatedViewModel.kt +++ b/app/src/main/kotlin/com/wire/android/ui/sharing/ImportMediaAuthenticatedViewModel.kt @@ -67,7 +67,6 @@ import kotlinx.coroutines.launch import kotlinx.coroutines.withContext import java.util.UUID import javax.inject.Inject -import kotlin.time.Duration.Companion.ZERO @HiltViewModel @OptIn(FlowPreview::class) @@ -458,5 +457,5 @@ data class ImportMediaAuthenticatedState( val isImporting: Boolean = false, val shareableConversationListState: ShareableConversationListState = ShareableConversationListState(), val selectedConversationItem: List = emptyList(), - val selfDeletingTimer: SelfDeletionTimer = SelfDeletionTimer.Enabled(ZERO) + val selfDeletingTimer: SelfDeletionTimer = SelfDeletionTimer.Enabled(null) )