blob: 6782ba5ad0a80e59b71ab6f7e8685ce51789b344 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
|
class SlackSlashCommandsService < ChatSlashCommandsService
include TriggersHelper
def title
'Slack Command'
end
def description
"Perform common operations on GitLab in Slack"
end
def to_param
'slack_slash_commands'
end
def trigger(params)
result = super
# Format messages to be Slack-compatible
if result && result[:text]
result[:text] = Slack::Notifier::LinkFormatter.format(result[:text])
end
result
end
end
|