blob: a03605d01fb5e507addb059755e0df1fa7b430cf (
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
27
28
29
30
31
32
33
34
|
require 'slack-notifier'
module ChatMessage
class BaseMessage
def initialize(params)
raise NotImplementedError
end
def pretext
format(message)
end
def fallback
end
def attachments
raise NotImplementedError
end
private
def message
raise NotImplementedError
end
def format(string)
Slack::Notifier::LinkFormatter.format(string)
end
def attachment_color
'#345'
end
end
end
|