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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 25f75fe95738928f39dc29cba7350c4106f48a2b
4
- data.tar.gz: 3a93bf1e383e987c5f6344a6d7d1d99150d46684
3
+ metadata.gz: 11510a4a0e35da5630eff5dc6e94784225dff973
4
+ data.tar.gz: c4d99a6dcbae908eb437f09387ddd60a4b9cce5c
5
5
  SHA512:
6
- metadata.gz: 5316c88ebcf6806ac32966fad7fb82fcf1363a236b2b5503926d65bc945fd9551338e2d316f681021736a2a49c6df26bebd7d51c4244f2f2f3c240a06443dc9d
7
- data.tar.gz: e7d76945472ae660b2645075831b226a49c11584005e803e8e754c6e79e383b4d2629c2c16a598c0b9ad9b1f2518998a6d6cf85bd0c081a7b74fbf9705bb4425
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
@@ -1,5 +1,5 @@
1
1
  module Ruboty
2
2
  module SlackRTM
3
- VERSION = '0.0.1'
3
+ VERSION = '0.0.2'
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ruboty-slack_rtm
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.1
4
+ version: 0.0.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Sho Kusano