ruboty-slack_rtm 0.0.1 → 0.0.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/ruboty/adapters/slack_rtm.rb +2 -1
- data/lib/ruboty/slack_rtm/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 11510a4a0e35da5630eff5dc6e94784225dff973
|
4
|
+
data.tar.gz: c4d99a6dcbae908eb437f09387ddd60a4b9cce5c
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: b6a2d177a7ee38661ebacd8a5a3ca2c1384dc951c040960242d29b4066c9630dfc36b5281060893e42132079ed0e65f310c78ac6a781558683a903f11858ee70
|
7
|
+
data.tar.gz: 5778e53030dc8526bfcef607c4c55863f6999b395bc582496c2d84127da9ed997779263b27d05db29b9492a0cd799fc58d046e3c7e65cb7f70d204023721f635
|
@@ -80,6 +80,7 @@ module Ruboty
|
|
80
80
|
to: data['channel'],
|
81
81
|
channel: channel_info(data['channel']),
|
82
82
|
user: user,
|
83
|
+
mention_to: data['mention_to'],
|
83
84
|
time: Time.at(data['ts'].to_f)
|
84
85
|
)
|
85
86
|
end
|
@@ -106,7 +107,7 @@ module Ruboty
|
|
106
107
|
|
107
108
|
data['mention_to'] = []
|
108
109
|
|
109
|
-
data['text'].gsub!(/\<\@(?<uid>[0-9A-Z]+)\>/) do |_|
|
110
|
+
(data['text'] || '').gsub!(/\<\@(?<uid>[0-9A-Z]+)\>/) do |_|
|
110
111
|
user = user_info(Regexp.last_match[:uid])
|
111
112
|
|
112
113
|
data['mention_to'] << user
|