Use request.content_type
This commit is contained in:
parent
a1520de7ed
commit
b8e3298925
1 changed files with 1 additions and 1 deletions
|
@ -41,7 +41,7 @@ module Kemal
|
||||||
{% end %}
|
{% end %}
|
||||||
|
|
||||||
private def parse_body
|
private def parse_body
|
||||||
content_type = @request.headers["Content-Type"]?
|
content_type = @request.content_type
|
||||||
return unless content_type
|
return unless content_type
|
||||||
if content_type.try(&.starts_with?(URL_ENCODED_FORM))
|
if content_type.try(&.starts_with?(URL_ENCODED_FORM))
|
||||||
@body = parse_part(@request.body)
|
@body = parse_part(@request.body)
|
||||||
|
|
Loading…
Reference in a new issue