Use request.content_type

This commit is contained in:
Serdar Dogruyol 2017-09-04 18:54:06 +03:00
parent a1520de7ed
commit b8e3298925
1 changed files with 1 additions and 1 deletions

View File

@ -41,7 +41,7 @@ module Kemal
{% end %}
private def parse_body
content_type = @request.headers["Content-Type"]?
content_type = @request.content_type
return unless content_type
if content_type.try(&.starts_with?(URL_ENCODED_FORM))
@body = parse_part(@request.body)