]> git.openstreetmap.org Git - rails.git/commitdiff
Use a lambda in order to pass parameters in before_actions
authorAndy Allan <git@gravitystorm.co.uk>
Wed, 20 Mar 2019 14:07:33 +0000 (15:07 +0100)
committerAndy Allan <git@gravitystorm.co.uk>
Wed, 20 Mar 2019 14:08:36 +0000 (15:08 +0100)
This avoid calling methods on a new instance of the controller, and
therefore allows these methods to be marked as private.

As a bonus, rubocop can now parse them and warn when they refer to
actions that don't exist in the controller.


No differences found