Skip to content

Commit 8b83a52

Browse files
author
t.chambard
committed
Merge remote-tracking branch 'origin/master' into feature/stream-file-param-decorator
# Conflicts: # src/metadata/parameterGenerator.ts
2 parents c002572 + 990aa14 commit 8b83a52

File tree

2 files changed

+15
-3
lines changed

2 files changed

+15
-3
lines changed

src/metadata/parameterGenerator.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
1-
import * as ts from 'typescript';
2-
import { getDecoratorName, getDecoratorOptions, getDecoratorTextValue } from '../utils/decoratorUtils';
31
import { MetadataGenerator, Parameter, Type } from './metadataGenerator';
4-
import { getCommonPrimitiveAndArrayUnionType, getLiteralValue, resolveType } from './resolveType';
2+
import { resolveType, getCommonPrimitiveAndArrayUnionType, getLiteralValue } from './resolveType';
3+
import { getDecoratorName, getDecoratorTextValue, getDecoratorOptions } from '../utils/decoratorUtils';
4+
import * as ts from 'typescript';
55

66
export class ParameterGenerator {
77
constructor(

test/data/apis.ts

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -387,6 +387,18 @@ export class ParameterizedEndpoint {
387387
stream(@swagger.StreamFileParam('stream') file: Express.Multer.File): PrimitiveClassModel {
388388
return new PrimitiveClassModel();
389389
}
390+
391+
@Path('/file')
392+
@POST
393+
file(@FileParam('file') file: Express.Multer.File): PrimitiveClassModel {
394+
return new PrimitiveClassModel();
395+
}
396+
397+
@Path('/stream')
398+
@POST
399+
stream(@swagger.StreamFileParam('stream') file: Express.Multer.File): PrimitiveClassModel {
400+
return new PrimitiveClassModel();
401+
}
390402
}
391403

392404
export abstract class Entity {

0 commit comments

Comments
 (0)