From 57c95ea7d60b6387027584bbca8e6d9efa04ac99 Mon Sep 17 00:00:00 2001 From: SessionHero01 <180888785+SessionHero01@users.noreply.github.com> Date: Tue, 24 Sep 2024 17:08:37 +1000 Subject: [PATCH] Set name --- .../org/thoughtcrime/securesms/groups/GroupManagerV2Impl.kt | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/app/src/main/java/org/thoughtcrime/securesms/groups/GroupManagerV2Impl.kt b/app/src/main/java/org/thoughtcrime/securesms/groups/GroupManagerV2Impl.kt index 6393ee0be5..20ce1349f5 100644 --- a/app/src/main/java/org/thoughtcrime/securesms/groups/GroupManagerV2Impl.kt +++ b/app/src/main/java/org/thoughtcrime/securesms/groups/GroupManagerV2Impl.kt @@ -1012,9 +1012,9 @@ class GroupManagerV2Impl @Inject constructor( override suspend fun setName(groupId: AccountId, newName: String): Unit = withContext(dispatcher) { val adminKey = requireAdminAccess(groupId) - configFactory.withGroupConfigsOrNull(groupId) { info, members, keys -> - info.setName(newName) - configFactory.saveGroupConfigs(keys, info, members) + configFactory.getGroupInfoConfig(groupId)?.use { infoConfig -> + infoConfig.setName(newName) + configFactory.persist(infoConfig, SnodeAPI.nowWithOffset, forPublicKey = groupId.hexString) } val groupDestination = Destination.ClosedGroup(groupId.hexString)