(input)
| 30777 | }; |
| 30778 | var ZodBoolean = class extends ZodType { |
| 30779 | _parse(input) { |
| 30780 | if (this._def.coerce) { |
| 30781 | input.data = Boolean(input.data); |
| 30782 | } |
| 30783 | const parsedType = this._getType(input); |
| 30784 | if (parsedType !== util_1.ZodParsedType.boolean) { |
| 30785 | const ctx = this._getOrReturnCtx(input); |
| 30786 | (0, parseUtil_1.addIssueToContext)(ctx, { |
| 30787 | code: ZodError_1.ZodIssueCode.invalid_type, |
| 30788 | expected: util_1.ZodParsedType.boolean, |
| 30789 | received: ctx.parsedType |
| 30790 | }); |
| 30791 | return parseUtil_1.INVALID; |
| 30792 | } |
| 30793 | return (0, parseUtil_1.OK)(input.data); |
| 30794 | } |
| 30795 | }; |
| 30796 | exports2.ZodBoolean = ZodBoolean; |
| 30797 | ZodBoolean.create = (params) => { |
no test coverage detected