Skip to content
This repository has been archived by the owner on Jan 13, 2023. It is now read-only.

Commit

Permalink
fix(types): Cast for TypeScript (#179 by @rdewolff)
Browse files Browse the repository at this point in the history
[skip ci]
  • Loading branch information
rdewolff authored and jamonholmgren committed May 5, 2019
1 parent ea1d736 commit 3136d4e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion boilerplate/app/utils/validate.ts
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ export interface ValidationErrors {
*/
export function validate(rules: ValidationRules, data: {}): ValidationErrors {
if (typeof data !== "object") {
return {}
return {} as ValidationErrors
}
return Validate(data, rules, { fullMessages: false }) || {}
}

0 comments on commit 3136d4e

Please sign in to comment.