commit a035f0ec1096d589d1fa3df9c3395137f3471126
parent 977d8b43270483034d729e09bc312f354c4fd595
Author: rhunk <101876869+rhunk@users.noreply.github.com>
Date:   Sun,  8 Dec 2024 17:12:16 +0100

fix(common): syncFriend

Diffstat:
Mapp/src/main/kotlin/me/rhunk/snapenhance/storage/Messaging.kt | 4++--
1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/app/src/main/kotlin/me/rhunk/snapenhance/storage/Messaging.kt b/app/src/main/kotlin/me/rhunk/snapenhance/storage/Messaging.kt @@ -63,12 +63,12 @@ fun AppDatabase.syncFriend(friend: MessagingFriendInfo) { ) ) //sync streaks - friend.streaks?.takeIf { it.length > 0 }?.let { + friend.streaks?.takeIf { it.length > 0 }?.also { val streaks = getFriendStreaks(friend.userId) database.execSQL("INSERT OR REPLACE INTO streaks (id, notify, expirationTimestamp, length) VALUES (?, ?, ?, ?)", arrayOf( friend.userId, - streaks?.notify ?: true, + streaks?.notify != false, it.expirationTimestamp, it.length ))