diff --git a/.rubocop.yml b/.rubocop.yml index 9b5067851..45c299599 100644 --- a/.rubocop.yml +++ b/.rubocop.yml @@ -469,6 +469,9 @@ Style/HashSyntax: Style/IdenticalConditionalBranches: Enabled: true +Style/IfWithBooleanLiteralBranches: + Enabled: true + Style/MethodDefParentheses: Enabled: true diff --git a/app/models/poll/booth_assignment.rb b/app/models/poll/booth_assignment.rb index 5af8e804c..e525b6ed7 100644 --- a/app/models/poll/booth_assignment.rb +++ b/app/models/poll/booth_assignment.rb @@ -12,7 +12,7 @@ class Poll has_many :recounts def shifts? - shifts.empty? ? false : true + !shifts.empty? end def unable_to_destroy?