Skip to content

Commit

Permalink
feat(validator): throw value in error
Browse files Browse the repository at this point in the history
  • Loading branch information
njfamirm authored and AliMD committed Jan 3, 2023
1 parent b48a30b commit 4e99b80
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions core/validator/src/validator.ts
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ function validator<DataType extends Record<string, unknown>>(value: Record<strin
throw new Error('invalid_type', {
cause: {
name: 'boolean_validator',
message: `'${validValue}' not valid`,
message: JSON.stringify(value),
},
});
}
Expand All @@ -37,7 +37,7 @@ function validator<DataType extends Record<string, unknown>>(value: Record<strin
throw new Error('invalid_type', {
cause: {
name: 'number_validator',
message: `'${validValue}' not valid`,
message: JSON.stringify(value),
},
});
}
Expand Down

0 comments on commit 4e99b80

Please sign in to comment.