(props: {
context: ITypiaContext;
metadata: MetadataSchema;
input: ts.Expression;
})
| 321 | }; |
| 322 | |
| 323 | const decode_array = (props: { |
| 324 | context: ITypiaContext; |
| 325 | metadata: MetadataSchema; |
| 326 | input: ts.Expression; |
| 327 | }): ts.Expression => |
| 328 | props.metadata.nullable || props.metadata.isRequired() === false |
| 329 | ? ts.factory.createCallExpression( |
| 330 | props.context.importer.internal("httpQueryReadArray"), |
| 331 | undefined, |
| 332 | [ |
| 333 | props.input, |
| 334 | props.metadata.nullable |
| 335 | ? ts.factory.createNull() |
| 336 | : ts.factory.createIdentifier("undefined"), |
| 337 | ], |
| 338 | ) |
| 339 | : props.input; |
| 340 | } |
no test coverage detected
searching dependent graphs…