mirror of
https://github.com/signalapp/Signal-Desktop.git
synced 2025-12-24 20:26:24 +00:00
Send and receive PniSignatureMessage
This commit is contained in:
@@ -34,7 +34,10 @@ import type {
|
||||
} from '../textsecure/SendMessage';
|
||||
import createTaskWithTimeout from '../textsecure/TaskWithTimeout';
|
||||
import MessageSender from '../textsecure/SendMessage';
|
||||
import type { CallbackResultType } from '../textsecure/Types.d';
|
||||
import type {
|
||||
CallbackResultType,
|
||||
PniSignatureMessageType,
|
||||
} from '../textsecure/Types.d';
|
||||
import type { ConversationType } from '../state/ducks/conversations';
|
||||
import type {
|
||||
AvatarColorType,
|
||||
@@ -2023,6 +2026,7 @@ export class ConversationModel extends window.Backbone
|
||||
senderE164: m.source,
|
||||
senderUuid: m.sourceUuid,
|
||||
timestamp: m.sent_at,
|
||||
isDirectConversation: isDirectConversation(this.attributes),
|
||||
}))
|
||||
);
|
||||
}
|
||||
@@ -5377,6 +5381,13 @@ export class ConversationModel extends window.Backbone
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
getPniSignatureMessage(): PniSignatureMessageType | undefined {
|
||||
if (!this.get('shareMyPhoneNumber')) {
|
||||
return undefined;
|
||||
}
|
||||
return window.textsecure.storage.protocol.signAlternateIdentity();
|
||||
}
|
||||
}
|
||||
|
||||
window.Whisper.Conversation = ConversationModel;
|
||||
|
||||
Reference in New Issue
Block a user