Skip to content

Commit

Permalink
[Fix rubocop#1039] Deprecate Rails/ActionFilter cop
Browse files Browse the repository at this point in the history
Fixes rubocop#1039.

This PR deprecates `Rails/ActionFilter` cop. Because the `*_filter` methods were removed in Rails 4.2,
and that Rals version is no longer supported by RuboCop Rails. This cop will be removed in RuboCop Rails 3.0.
  • Loading branch information
koic committed Oct 10, 2023
1 parent bd7ee99 commit 1874ad8
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 0 deletions.
1 change: 1 addition & 0 deletions changelog/change_deprecate_rails_action_filter_cop.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
* [#1039](https://github.com/rubocop/rubocop-rails/issues/1039): Deprecate `Rails/ActionFilter` cop. ([@koic][])
3 changes: 3 additions & 0 deletions lib/rubocop/cop/rails/action_filter.rb
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,9 @@ module Rails
# The cop is configurable and can enforce the use of the older
# something_filter methods or the newer something_action methods.
#
# IMPORTANT: This cop is deprecated. Because the `*_filter` methods were removed in Rails 4.2,
# and that Rals version is no longer supported by RuboCop Rails. This cop will be removed in RuboCop Rails 3.0.
#
# @example EnforcedStyle: action (default)
# # bad
# after_filter :do_stuff
Expand Down

0 comments on commit 1874ad8

Please sign in to comment.