mirror of
https://github.com/Growstuff/growstuff.git
synced 2026-01-26 02:07:58 -05:00
rubocop fix for redundant self assignment
This commit is contained in:
@@ -345,12 +345,6 @@ Style/RegexpLiteral:
|
||||
- 'spec/views/posts/index.html.haml_spec.rb'
|
||||
- 'spec/views/posts/show.html.haml_spec.rb'
|
||||
|
||||
# Offense count: 1
|
||||
# Cop supports --auto-correct.
|
||||
Style/SelfAssignment:
|
||||
Exclude:
|
||||
- 'app/helpers/crops_helper.rb'
|
||||
|
||||
# Offense count: 2
|
||||
# Cop supports --auto-correct.
|
||||
# Configuration parameters: SupportedStyles.
|
||||
|
||||
@@ -5,7 +5,7 @@ module CropsHelper
|
||||
seeds = member.seeds.select { |seed| seed.crop.name == crop.name }
|
||||
|
||||
seeds.each do |seed|
|
||||
total_quantity = total_quantity + seed.quantity if seed.quantity
|
||||
total_quantity += seed.quantity if seed.quantity
|
||||
end
|
||||
|
||||
if !seeds.any?
|
||||
|
||||
Reference in New Issue
Block a user