Skip to content

Commit

Permalink
Don't attempt to parse body when content-type is NIL
Browse files Browse the repository at this point in the history
  • Loading branch information
Yrjänä Rankka committed Sep 6, 2019
1 parent 2921d36 commit 9c607b8
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion v1-compat/src/core/request.lisp
Expand Up @@ -181,7 +181,8 @@ on an original raw-body."

(setf (getf env :raw-body) (slot-value req 'raw-body))
;; POST parameters
(unless (slot-boundp req 'body-parameters)
(unless (or (null (content-type req))
(slot-boundp req 'body-parameters))
(setf (slot-value req 'body-parameters)
(parse (content-type req) (content-length req) (raw-body req)))
(file-position (raw-body req) 0)
Expand Down

0 comments on commit 9c607b8

Please sign in to comment.