Class: Commands::Ack
Instance Method Summary collapse
Methods included from Base
#current_user, #format_incident, #format_incidents, #format_note, #format_notes, included, #initialize, #pagerduty, #response, #store
Instance Method Details
#call ⇒ Object
5 6 7 8 9 10 11 12 13 |
# File 'lib/lita/commands/ack.rb', line 5 def call incident_id = .match_data['incident_id'] return if incident_id =~ /\A(all|mine)\z/i pagerduty.manage_incidents(:acknowledge, [incident_id]) response message: 'all.acknowledged', params: { list: incident_id.to_s } rescue Exceptions::IncidentManageUnsuccess nil end |