Add an apply StringConversionInInterpolation rule

This commit is contained in:
Javi Martín
2019-09-28 22:29:25 +02:00
parent 9c3686a6d8
commit 6ffe563264
2 changed files with 6 additions and 3 deletions

View File

@@ -126,6 +126,9 @@ Lint/LiteralAsCondition:
Lint/ShadowingOuterLocalVariable: Lint/ShadowingOuterLocalVariable:
Enabled: true Enabled: true
Lint/StringConversionInInterpolation:
Enabled: true
Lint/UselessAssignment: Lint/UselessAssignment:
Enabled: true Enabled: true

View File

@@ -21,9 +21,9 @@ class Poll::PartialResult < ApplicationRecord
def update_logs def update_logs
if amount_changed? && amount_was.present? if amount_changed? && amount_was.present?
self.amount_log += ":#{amount_was.to_s}" self.amount_log += ":#{amount_was}"
self.officer_assignment_id_log += ":#{officer_assignment_id_was.to_s}" self.officer_assignment_id_log += ":#{officer_assignment_id_was}"
self.author_id_log += ":#{author_id_was.to_s}" self.author_id_log += ":#{author_id_was}"
end end
end end
end end