Skip to content

Commit 0030557

Browse files
committed
fix(makeError): fix type error
1 parent e076583 commit 0030557

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/makeError.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ export default function makeError(
77
input: any
88
): TypeError | null | undefined {
99
const validation = new Validation(input)
10-
validation.errors = Array.from(expected.errors(validation, [], input))
10+
for (const error of expected.errors(validation, [], input))
11+
validation.errors.push(error)
1112
return makeTypeError(validation)
1213
}

0 commit comments

Comments
 (0)