Skip to content

Commit

Permalink
apply pr suggestions, part 2
Browse files Browse the repository at this point in the history
  • Loading branch information
piotr-roslaniec committed Jun 27, 2023
1 parent f682eb2 commit 1b2ae4e
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/characters/cbd-recipient.ts
Original file line number Diff line number Diff line change
Expand Up @@ -96,12 +96,12 @@ export class CbdTDecDecrypter {
encryptedRequests,
this.threshold
);

if (Object.keys(errors).length > 0) {
if (Object.keys(encryptedResponses).length < this.threshold) {
throw new Error(
`CBD decryption failed with errors: ${JSON.stringify(errors)}`
);
}

return this.makeDecryptionShares(
encryptedResponses,
sharedSecrets,
Expand Down

0 comments on commit 1b2ae4e

Please sign in to comment.