()
| 369 | else |
| 370 | validateFormat(); |
| 371 | function validate$DataFormat() { |
| 372 | const fmts = gen.scopeValue("formats", { |
| 373 | ref: self.formats, |
| 374 | code: opts.code.formats, |
| 375 | }); |
| 376 | const fmt = gen.const("fmt", codegen_1._ `${fmts}[${fCxt.schemaCode}]`); |
| 377 | cxt.fail$data(codegen_1.or(codegen_1._ `typeof ${fmt} != "object"`, codegen_1._ `${fmt} instanceof RegExp`, codegen_1._ `typeof ${fmt}.compare != "function"`, compareCode(fmt))); |
| 378 | } |
| 379 | function validateFormat() { |
| 380 | const format = fCxt.schema; |
| 381 | const fmtDef = self.formats[format]; |
no test coverage detected