Add and apply Style/IfWithBooleanLiteralBranches
This rule was added in Rubocop 1.9.0.
This commit is contained in:
@@ -469,6 +469,9 @@ Style/HashSyntax:
|
|||||||
Style/IdenticalConditionalBranches:
|
Style/IdenticalConditionalBranches:
|
||||||
Enabled: true
|
Enabled: true
|
||||||
|
|
||||||
|
Style/IfWithBooleanLiteralBranches:
|
||||||
|
Enabled: true
|
||||||
|
|
||||||
Style/MethodDefParentheses:
|
Style/MethodDefParentheses:
|
||||||
Enabled: true
|
Enabled: true
|
||||||
|
|
||||||
|
|||||||
@@ -12,7 +12,7 @@ class Poll
|
|||||||
has_many :recounts
|
has_many :recounts
|
||||||
|
|
||||||
def shifts?
|
def shifts?
|
||||||
shifts.empty? ? false : true
|
!shifts.empty?
|
||||||
end
|
end
|
||||||
|
|
||||||
def unable_to_destroy?
|
def unable_to_destroy?
|
||||||
|
|||||||
Reference in New Issue
Block a user