Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fixes #1362. This PR fixes false positives for `Rails/EnumSyntax` when using Ruby 2.7. The warning shown in #1238 appears starting from Rails 7.2 (Requires Ruby 3.1+). On the other hand, if users use Ruby 2.7, the warning reported in #1362 will be displayed. Therefore, it would be appropriate to enable this cop only when analyzing Ruby 3.0+. Nothing will happen when using Ruby 2.7 with Rails 7.0 or Rails 7.1, but the warning in #1238 will not be displayed either. Meanwhile, in Rails 7.2, which requires Ruby 3.1+, Ruby 2.7 cannot be used, so there is no issue.
- Loading branch information