Skip to content

Commit

Permalink
Fixes error undefined, throw error instead
Browse files Browse the repository at this point in the history
  • Loading branch information
Sata51 authored and minggangw committed Apr 3, 2023
1 parent 10229a2 commit a14527b
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions lib/client.js
Original file line number Diff line number Diff line change
Expand Up @@ -70,8 +70,9 @@ class Client extends Entity {
this._sequenceNumberToCallbackMap.delete(sequenceNumber);
callback(response.toPlainObject(this.typedArrayEnabled));
} else {
error(`Client has received an unexpected ${this._serviceName}
response with sequence number ${sequenceNumber}.`);
throw new Error(
`Client has received an unexpected ${this._serviceName} with sequence number ${sequenceNumber}.`
);
}
}

Expand Down

0 comments on commit a14527b

Please sign in to comment.