Add X-Powered-By header

This commit is contained in:
Sdogruyol 2016-06-19 03:22:55 +03:00
parent 56067b6280
commit 0c46bd65da
2 changed files with 8 additions and 0 deletions

View file

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