fgalassi/Slim — comment on commit 88703b0efd9b93131efc4558d17299920b0e8cab
File:  line 0
By fgalassi:

I think it's ok, because this is all non standard stuff. Maybe you can add "and if body is not empty" because it doesn't make sense to assign a content-type to an empty body (e.g. GET). About my commit, i was just copying rack. They probably added it as a practical fix to some broken client.

def form_data?
type = media_type
meth = env["rack.methodoverride.original_method"] || env['REQUEST_METHOD']
(meth == 'POST' && type.nil?) || FORM_DATA_MEDIA_TYPES.include?(type)
end