1
0
Fork 0
mirror of https://github.com/rails/rails.git synced 2022-11-09 12:12:34 -05:00

we only care about methods that the request object responds to

matches? should only deal with methods on the request object, so lets
just filter out anything that the request object doesn't respond to
This commit is contained in:
Aaron Patterson 2015-06-08 17:23:14 -07:00
parent 8037d7eacd
commit 877c133855

View file

@ -564,8 +564,7 @@ module ActionDispatch
end
conditions.keep_if do |k, _|
k == :action || k == :controller ||
request_class.public_method_defined?(k) || path_values.include?(k)
request_class.public_method_defined?(k)
end
end
private :build_conditions