Inherit response.content type from filter if it's given. Fixes #146.

This commit is contained in:
Sdogruyol 2016-05-14 11:07:19 +03:00
parent c2edc89992
commit 92d7273759
2 changed files with 10 additions and 1 deletions

View file

@ -13,7 +13,7 @@ class Kemal::RouteHandler < HTTP::Handler
end
def call(context)
context.response.content_type = "text/html"
context.response.content_type = "text/html" unless context.response.headers.has_key?("Content-Type")
process_request(context)
end