lib/grape/router.rb in grape-2.1.0 vs lib/grape/router.rb in grape-2.1.1
- old
+ new
@@ -136,10 +136,11 @@
compile! unless compiled
yield || default_response
end
def default_response
- [404, { Grape::Http::Headers::X_CASCADE => 'pass' }, ['404 Not Found']]
+ headers = Grape::Util::Header.new.merge(Grape::Http::Headers::X_CASCADE => 'pass')
+ [404, headers, ['404 Not Found']]
end
def match?(input, method)
@optimized_map[method].match(input) { |m| @map[method].detect { |route| m[route.regexp_capture_index] } }
end