Remove literal used in condition
The right syntax would have been: `after_save :recalculate_heading_winners, if: :incompatible_changed?` However, since the method `recalculate_heading_winners` already executes the `if incompatible_changed?` condition, removing it keeps the intended behaviour.
This commit is contained in:
@@ -95,7 +95,7 @@ class Budget
|
||||
scope :for_render, -> { includes(:heading) }
|
||||
|
||||
before_save :calculate_confidence_score
|
||||
after_save :recalculate_heading_winners if :incompatible_changed?
|
||||
after_save :recalculate_heading_winners
|
||||
before_validation :set_responsible_name
|
||||
before_validation :set_denormalized_ids
|
||||
|
||||
|
||||
Reference in New Issue
Block a user