Skip to content

Commit 3b9f960

Browse files
Merge pull request #35 from alessandrovaccaro/response-schemas
if @response then override default behaviour
2 parents 8c9347c + 70fa5f8 commit 3b9f960

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/metadata/methodGenerator.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,9 @@ export class MethodGenerator {
3333
const identifier = this.node.name as ts.Identifier;
3434
const type = resolveType(this.node.type, this.genericTypeMap);
3535
const responses = this.getMethodResponses();
36-
responses.push(this.getMethodSuccessResponse(type));
36+
if (0 === responses.length) {
37+
responses.push(this.getMethodSuccessResponse(type));
38+
}
3739

3840
return {
3941
consumes: this.getDecoratorValues('Accept'),

0 commit comments

Comments
 (0)