Update profile sharing when added to group

This commit is contained in:
trevor-signal
2025-08-25 10:26:49 -04:00
committed by GitHub
parent 5e44de3bd7
commit 435dc2acf7
3 changed files with 35 additions and 38 deletions

View File

@@ -4185,29 +4185,6 @@ export class ConversationModel {
return attributes;
}
// Is this someone who is a contact, or are we sharing our profile with them?
// Or is the person who added us to this group a contact or are we sharing profile
// with them?
isFromOrAddedByTrustedContact(): boolean {
if (isDirectConversation(this.attributes)) {
return Boolean(this.get('name')) || Boolean(this.get('profileSharing'));
}
const addedBy = this.get('addedBy');
if (!addedBy) {
return false;
}
const conv = window.ConversationController.get(addedBy);
if (!conv) {
return false;
}
return Boolean(
isMe(conv.attributes) || conv.get('name') || conv.get('profileSharing')
);
}
async maybeClearUsername(): Promise<void> {
const ourConversationId =
window.ConversationController.getOurConversationId();