mirror of
https://github.com/oxen-io/session-android.git
synced 2025-10-17 13:21:55 +00:00
Added the legacy group 'joined_at' value
This commit is contained in:
@@ -564,7 +564,7 @@ open class Storage(context: Context, helper: SQLCipherOpenHelper, private val co
|
||||
val admins = group.members.filter { it.value /*admin = true*/ }.keys.map { Address.fromSerialized(it) }
|
||||
val groupId = GroupUtil.doubleEncodeGroupID(group.sessionId)
|
||||
val title = group.name
|
||||
val formationTimestamp = SnodeAPI.nowWithOffset // TODO: formation timestamp for legacy ? current time?
|
||||
val formationTimestamp = group.joinedAt
|
||||
createGroup(groupId, title, members, null, null, admins, formationTimestamp)
|
||||
setProfileSharing(Address.fromSerialized(groupId), true)
|
||||
// Add the group to the user's set of public keys to poll for
|
||||
@@ -835,7 +835,8 @@ open class Storage(context: Context, helper: SQLCipherOpenHelper, private val co
|
||||
priority = ConfigBase.PRIORITY_VISIBLE,
|
||||
encPubKey = encryptionKeyPair.publicKey.serialize(),
|
||||
encSecKey = encryptionKeyPair.privateKey.serialize(),
|
||||
disappearingTimer = 0L
|
||||
disappearingTimer = 0L,
|
||||
joinedAt = formationTimestamp
|
||||
)
|
||||
// shouldn't exist, don't use getOrConstruct + copy
|
||||
userGroups.set(groupInfo)
|
||||
|
@@ -256,7 +256,8 @@ object ConfigurationMessageUtilities {
|
||||
priority = if (isPinned) ConfigBase.PRIORITY_PINNED else ConfigBase.PRIORITY_VISIBLE,
|
||||
encPubKey = encryptionKeyPair.publicKey.serialize(),
|
||||
encSecKey = encryptionKeyPair.privateKey.serialize(),
|
||||
disappearingTimer = recipient.expireMessages.toLong()
|
||||
disappearingTimer = recipient.expireMessages.toLong(),
|
||||
joinedAt = group.formationTimestamp
|
||||
)
|
||||
}
|
||||
(allOpenGroups + allLgc).forEach { groupInfo ->
|
||||
|
Reference in New Issue
Block a user