Skip to content

Commit

Permalink
fix: fixing issuer not included in the allowed field names
Browse files Browse the repository at this point in the history
  • Loading branch information
artursudnik committed Sep 29, 2023
1 parent de01fda commit f624b11
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ import {
} from 'class-validator';
import { ValidationArguments } from 'class-validator/types/validation/ValidationArguments';

export const allowedFieldNames = ['@context', 'credentialSubject', 'id', 'issuanceDate', 'type'];
export const allowedFieldNames = ['@context', 'credentialSubject', 'id', 'issuanceDate', 'type', 'issuer'];

@ValidatorConstraint({ async: false })
export class IsAllowedFieldJsonPathKeyConstraint implements ValidatorConstraintInterface {
Expand Down
2 changes: 1 addition & 1 deletion apps/input-descriptor-to-credential/test/app.e2e-spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ describe('AppController (e2e)', () => {
expect(result.body).toEqual({
error: 'Bad Request',
message: [
'constraints.fields.0.path property key name value must be one of the allowed string values: @context,credentialSubject,id,issuanceDate,type',
'constraints.fields.0.path property key name value must be one of the allowed string values: @context,credentialSubject,id,issuanceDate,type,issuer',
'constraints.fields needs to be an array of objects with at least the following path field values: $.@context, $.credentialSubject, $.type'
],
statusCode: 400
Expand Down

0 comments on commit f624b11

Please sign in to comment.