From 4f3955657736796664aa8d6f6d149ef9b213b058 Mon Sep 17 00:00:00 2001 From: dixpac Date: Sat, 13 May 2017 13:56:37 +0200 Subject: Improving docs for callbacks execution order [ci skip] When define callbacks latest definition on the same callback/method overwrites previous ones. --- guides/source/action_controller_overview.md | 3 +++ 1 file changed, 3 insertions(+) (limited to 'guides') diff --git a/guides/source/action_controller_overview.md b/guides/source/action_controller_overview.md index 5d987264f5..22537f960c 100644 --- a/guides/source/action_controller_overview.md +++ b/guides/source/action_controller_overview.md @@ -715,6 +715,9 @@ end Now, the `LoginsController`'s `new` and `create` actions will work as before without requiring the user to be logged in. The `:only` option is used to skip this filter only for these actions, and there is also an `:except` option which works the other way. These options can be used when adding filters too, so you can add a filter which only runs for selected actions in the first place. +NOTE: Calling the same filter multiple times with different options will not work, +since the last filter definition will overwrite the previous ones. + ### After Filters and Around Filters In addition to "before" filters, you can also run filters after an action has been executed, or both before and after. -- cgit v1.2.3