Skip to content

Commit edcae93

Browse files
koicbbatsov
authored andcommitted
[Fix #11800] Mark Style/InvertibleUnlessCondition as unsafe
Fixes #11800. This PR marks `Style/InvertibleUnlessCondition` as unsafe. `@safety` is already documented: https://github.com/rubocop/rubocop/blob/v1.50.1/lib/rubocop/cop/style/invertible_unless_condition.rb#L20-L23
1 parent 8dfe1b4 commit edcae93

File tree

2 files changed

+3
-0
lines changed

2 files changed

+3
-0
lines changed
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
* [#11800](https://github.com/rubocop/rubocop/issues/11800): Mark `Style/InvertibleUnlessCondition` as unsafe. ([@koic][])

config/default.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4067,7 +4067,9 @@ Style/InverseMethods:
40674067
Style/InvertibleUnlessCondition:
40684068
Description: 'Favor `if` with inverted condition over `unless`.'
40694069
Enabled: false
4070+
Safe: false
40704071
VersionAdded: '1.44'
4072+
VersionChanged: '<<next>>'
40714073
# `InverseMethods` are methods that can be inverted in a `unless` condition.
40724074
# The relationship of inverse methods needs to be defined in both directions.
40734075
# Keys and values both need to be defined as symbols.

0 commit comments

Comments
 (0)