Simplify OutgoingIdentityKeyError, use it in getKeysForIdentifier
This commit is contained in:
parent
e4b4a0cd1e
commit
fcb96bf92a
6 changed files with 32 additions and 33 deletions
|
@ -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;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue