Simplify OutgoingIdentityKeyError, use it in getKeysForIdentifier

This commit is contained in:
Scott Nonnenberg 2022-02-25 15:39:24 -08:00 committed by GitHub
parent e4b4a0cd1e
commit fcb96bf92a
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
6 changed files with 32 additions and 33 deletions

View file

@ -73,15 +73,8 @@ export class ReplayableError extends Error {
export class OutgoingIdentityKeyError extends ReplayableError {
identifier: string;
identityKey: Uint8Array;
// Note: Data to resend message is no longer captured
constructor(
incomingIdentifier: string,
_m: Uint8Array,
_t: number,
identityKey: Uint8Array
) {
constructor(incomingIdentifier: string) {
const identifier = incomingIdentifier.split('.')[0];
super({
@ -90,7 +83,6 @@ export class OutgoingIdentityKeyError extends ReplayableError {
});
this.identifier = identifier;
this.identityKey = identityKey;
}
}