Who cares? There are not going to be 10k elements here. This perf difference is of no impact and it reads far better.

On Jan 5, 2013, at 8:32, Rafael Mendonça França <notifications@github.com> wrote:

> In actionpack/lib/action_controller/metal/strong_parameters.rb:
> 
> > @@ -223,6 +238,13 @@ def permit(*filters)
> >          end
> >        end
> >  
> > +      if Parameters.raise_on_unexpected
> > +        unexpected_keys = self.keys - params.keys
> > +        unless unexpected_keys.empty?
> > +          raise ActionController::UnexpectedParameters.new(unexpected_keys)
> any? does an unnecessary pass in the elements to check if they are nil or false.
> 
> —
> Reply to this email directly or view it on GitHub.
>