Skip to content

Commit 17f73e1

Browse files
author
Kumanan Rajamanikkam
committed
Fixed SwaggerRequest logic to support PUTs
1 parent be28666 commit 17f73e1

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

lib/swagger.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/swagger.coffee

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -169,7 +169,7 @@ class SwaggerRequest
169169
success: (data) =>
170170
@callback(data)
171171

172-
obj.contentType = "application/json" if obj.type.toLowerCase() == "post"
172+
obj.contentType = "application/json" if (obj.type.toLowerCase() == "post" or obj.type.toLowerCase() == "put")
173173

174174
$.ajax(obj)
175175

0 commit comments

Comments
 (0)