mirror of
https://github.com/signalapp/Signal-Desktop.git
synced 2026-04-26 03:18:17 +01:00
Simplify OutgoingIdentityKeyError, use it in getKeysForIdentifier
This commit is contained in:
@@ -707,12 +707,7 @@ export default class OutgoingMessage {
|
||||
await this.reloadDevicesAndSend(identifier, true)();
|
||||
} catch (error) {
|
||||
if (error?.message?.includes('untrusted identity for address')) {
|
||||
const newError = new OutgoingIdentityKeyError(
|
||||
identifier,
|
||||
error.originalMessage,
|
||||
error.timestamp,
|
||||
error.identityKey && new Uint8Array(error.identityKey)
|
||||
);
|
||||
const newError = new OutgoingIdentityKeyError(identifier);
|
||||
this.registerError(identifier, 'Untrusted identity', newError);
|
||||
} else {
|
||||
this.registerError(
|
||||
|
||||
Reference in New Issue
Block a user