diff options
author | Rick Olson <technoweenie@gmail.com> | 2008-03-23 01:48:17 +0000 |
---|---|---|
committer | Rick Olson <technoweenie@gmail.com> | 2008-03-23 01:48:17 +0000 |
commit | 038139870825ad843b0683e5273dc4d11cb684b3 (patch) | |
tree | a9dc8f1416a28206ddaca9ad9f9aa38d25613f6d /actionpack/lib | |
parent | 29e33161784dae84b1e92f9acf9db7d0f1d0da64 (diff) | |
download | rails-038139870825ad843b0683e5273dc4d11cb684b3.tar.gz rails-038139870825ad843b0683e5273dc4d11cb684b3.tar.bz2 rails-038139870825ad843b0683e5273dc4d11cb684b3.zip |
Fix regression from filter refactoring where re-adding a skipped filter resulted in it being called twice. [rick]
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@9080 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
Diffstat (limited to 'actionpack/lib')
-rw-r--r-- | actionpack/lib/action_controller/filters.rb | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/actionpack/lib/action_controller/filters.rb b/actionpack/lib/action_controller/filters.rb index a822ffe4e4..218a9c0b80 100644 --- a/actionpack/lib/action_controller/filters.rb +++ b/actionpack/lib/action_controller/filters.rb @@ -264,6 +264,9 @@ module ActionController #:nodoc: def skip_filter_in_chain(*filters, &test) filters, conditions = extract_options(filters) + filters.each do |filter| + if callback = find_callback(filter) then delete(callback) end + end if conditions.empty? update_filter_in_chain(filters, :skip => conditions, &test) end |