Method: OpenC3::ReactionModel#activate

Defined in:
lib/openc3/models/reaction_model.rb

#activateObject



223
224
225
226
227
228
229
# File 'lib/openc3/models/reaction_model.rb', line 223

def activate
  @active = true
  @snoozed_until = nil if @snoozed_until && @snoozed_until < Time.now.to_i
  @updated_at = Time.now.to_nsec_from_epoch
  Store.hset(@primary_key, @name, JSON.generate(as_json(:allow_nan => true)))
  notify(kind: 'activated')
end