mirror of
https://github.com/signalapp/Signal-Android.git
synced 2026-04-22 01:40:07 +01:00
Add better application error handling for badges and token redemption.
This commit is contained in:
committed by
Greyson Parrelli
parent
2b6190bf34
commit
b8dc541fc5
@@ -36,6 +36,10 @@ data class Badge(
|
||||
val visible: Boolean,
|
||||
) : Parcelable, Key {
|
||||
|
||||
fun setVisible(): Badge {
|
||||
return copy(visible = true)
|
||||
}
|
||||
|
||||
fun isExpired(): Boolean = expirationTimestamp < System.currentTimeMillis() && expirationTimestamp > 0
|
||||
fun isBoost(): Boolean = id == BOOST_BADGE_ID
|
||||
|
||||
|
||||
Reference in New Issue
Block a user