Fix non-sms messages not deserialisable by kryo

This commit is contained in:
Andrew 2024-02-09 11:12:17 +10:30
parent 84e92e186b
commit 181dd15028

View File

@ -4,9 +4,9 @@ import kotlin.time.Duration.Companion.seconds
sealed class ExpiryMode(val expirySeconds: Long) {
object NONE: ExpiryMode(0)
data class Legacy(private val seconds: Long): ExpiryMode(seconds)
data class AfterSend(private val seconds: Long): ExpiryMode(seconds)
data class AfterRead(private val seconds: Long): ExpiryMode(seconds)
data class Legacy(private val seconds: Long = 0L): ExpiryMode(seconds)
data class AfterSend(private val seconds: Long = 0L): ExpiryMode(seconds)
data class AfterRead(private val seconds: Long = 0L): ExpiryMode(seconds)
val duration get() = expirySeconds.seconds