lita-message-router 0.1.3 → 0.1.4

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: 97970436923da151ae36de9316d28dbee6e1afa3
4
- data.tar.gz: e36c63d808d9319c26224ccf1617b172f8e104c4
3
+ metadata.gz: cf925299bd05945cf6fafc674f306e56f27c1352
4
+ data.tar.gz: 7f6cc2f1dd111190f2612746e5c7c9a54e3b75fb
5
5
  SHA512:
6
- metadata.gz: e9385feaa66126987872336c36c406089dbf5864462aa9fbdd5dd8694de23185749b99f625194bf2192531b2d2a7fed93448bb8525a1ebf0192803043f947832
7
- data.tar.gz: 7033c84dc456eb4b873af08e87ef6170443e6b02dd76a30b3410048eeb55c43e5fc63a4eae4432720205a39dfc4c012de07ae910304de6d30836a91fb062d333
6
+ metadata.gz: 4a8dab3dee1b2f6cc57db8184d65f1a9bf73886010fa225ec73573ba59f304804f4d29d82b877500a966f22f8d905f9eee7be7bcc03c2e8fbe84f2260d0a9a9e
7
+ data.tar.gz: f98d8f8f0829c5b9fd62c6b9b88545fb470d07a109f4b665db8df54ae78d77a974ffa349ff4f7907cf83db8ed3cdc9b29590c5c5eab711873de718f6d3fe1284
@@ -13,7 +13,14 @@ module Lita
13
13
 
14
14
  if match
15
15
  command = robot.mention_name + ' ' + match
16
- real_message = Lita::Message.new(robot, command, Lita::Source.new(user: chat.user))
16
+
17
+ source = if chat.room
18
+ Lita::Source.new(room: chat.room)
19
+ else
20
+ Lita::Source.new(user: chat.user)
21
+ end
22
+
23
+ real_message = Lita::Message.new(robot, command, source)
17
24
  robot.receive(real_message)
18
25
  end
19
26
  end
@@ -1,6 +1,6 @@
1
1
  Gem::Specification.new do |spec|
2
2
  spec.name = "lita-message-router"
3
- spec.version = "0.1.3"
3
+ spec.version = "0.1.4"
4
4
  spec.authors = ["Taylor Lapeyre"]
5
5
  spec.email = ["taylorlapeyre@gmail.com"]
6
6
  spec.description = "This handler allows you to specify as many 'mention names' as you want for your Lita robot."
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: lita-message-router
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.3
4
+ version: 0.1.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Taylor Lapeyre