lita-discord_oauth 0.1.2.alpha.95 → 0.1.2.alpha.96
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/lita/adapters/discord_oauth.rb +5 -3
- data/lib/lita/handlers/discord_help.rb +6 -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: b94d55ce9b25a25d137aebea99513f6d7f021e3d
|
4
|
+
data.tar.gz: 735bc81262a8d0978291a50fd893923c8fbf78ba
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 28fd15d1844eeb83b2ee305ea363dbb2eb891a2bc6dd14bfa15a1b42d20d75962dc31e73247a61b33378033158399b79bf2c4683e5fbe0ada85216e62af6e8c6
|
7
|
+
data.tar.gz: d9e89e39d4944a800be7b8a1441a7885b3abb09dca9800a734c0c55b5ac732c33509da2fea342bb0e00ae0446cc84982c12963af6698c7fd3c7c277fded15df7
|
@@ -79,11 +79,13 @@ module Lita
|
|
79
79
|
|
80
80
|
messages.each do |message|
|
81
81
|
if mention
|
82
|
-
|
82
|
+
no_mention = message.slice!('|||NOMENTION|||')
|
83
83
|
|
84
|
-
|
84
|
+
message = mention + ",\n" + message if no_mention != '|||NOMENTION|||'
|
85
85
|
|
86
|
-
|
86
|
+
|
87
|
+
|
88
|
+
Lita.logger.info('Message is too long') if message.length > 2000
|
87
89
|
|
88
90
|
@client.send_message(target.room, message)
|
89
91
|
end
|
@@ -18,6 +18,7 @@ module Lita
|
|
18
18
|
def help(response)
|
19
19
|
output = build_help(response)
|
20
20
|
output = filter_help(output, response)
|
21
|
+
first_message = true
|
21
22
|
|
22
23
|
output = output.join("\n")
|
23
24
|
|
@@ -26,7 +27,11 @@ module Lita
|
|
26
27
|
Lita.logger.debug(messages)
|
27
28
|
|
28
29
|
messages.each { |message|
|
29
|
-
|
30
|
+
if first_message
|
31
|
+
response.reply_privately("```\n#{message}\n```")
|
32
|
+
else
|
33
|
+
response.reply_privately("|||NOMENTION|||```\n#{message}\n```")
|
34
|
+
end
|
30
35
|
sleep(0.2)
|
31
36
|
}
|
32
37
|
|