Skip to content

Commit f5671a7

Browse files
committed
chore: update error for verifying bit string status list credential
Signed-off-by: Krishna Waske <[email protected]>
1 parent 7c6edc8 commit f5671a7

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

packages/core/src/modules/vc/models/credential/w3c-credential-status/bitstring-status-list/VerifyBitStringCredentialStatus.ts

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,10 @@ export const verifyBitStringCredentialStatus = async (
5555

5656
// Check if the credential is revoked
5757
if (decodedBitString[statusListIndex] === '1') {
58-
throw new CredoError(`Credential at index ${credentialStatus.statusListIndex} is revoked.`)
58+
// To do: The error can be updated once we add support for status messages
59+
throw new CredoError(
60+
`Credential at index ${credentialStatus.statusListIndex} is in ${bitStringStatusListCredential.credentialSubject.statusPurpose} state.`
61+
)
5962
}
6063

6164
return true

0 commit comments

Comments
 (0)