Fix profile name not updating correctly.

This commit is contained in:
Cody Henthorne
2024-02-21 15:29:17 -05:00
committed by Greyson Parrelli
parent d5cf8d36b3
commit 16faf41a84
2 changed files with 6 additions and 2 deletions

View File

@@ -4112,7 +4112,8 @@ open class RecipientTable(context: Context, databaseHelper: SignalDatabase) : Da
PROFILE_FAMILY_NAME to null,
PROFILE_JOINED_NAME to null,
LAST_PROFILE_FETCH to 0,
PROFILE_AVATAR to null
PROFILE_AVATAR to null,
PROFILE_SHARING to 0
)
.run {
if (recipientId == null) {

View File

@@ -384,9 +384,12 @@ class RetrieveProfileJob private constructor(parameters: Parameters, private val
}
if (writeChangeEvent || localDisplayName.isEmpty()) {
ApplicationDependencies.getDatabaseObserver().notifyConversationListListeners()
val threadId = SignalDatabase.threads.getThreadIdFor(recipient.id)
if (threadId != null) {
ApplicationDependencies.getMessageNotifier().updateNotification(context, forConversation(threadId))
SignalDatabase.runPostSuccessfulTransaction {
ApplicationDependencies.getMessageNotifier().updateNotification(context, forConversation(threadId))
}
}
}