Quick correction, so that nil repeatitions will not generate an exception

This commit is contained in:
echarp 2017-11-12 19:12:48 +01:00
parent 1614e876d2
commit 5efd394ce8

View File

@ -16,7 +16,7 @@ class EventCallbacks
def self.before_update(event)
return unless event.moderated_changed? && event.moderated?
event.decision_time = Time.zone.now
create_repeats event if event.repeat > 0 && event.rule
create_repeats event if event.repeat.try(:positive?) && event.rule
end
def self.after_update(event)