discordrb 1.0.7 → 1.0.8
Sign up to get free protection for your applications and to get access to all the features.
Potentially problematic release.
This version of discordrb might be problematic. Click here for more details.
- checksums.yaml +4 -4
- data/lib/discordrb/bot.rb +3 -2
- data/lib/discordrb/events/generic.rb +2 -0
- data/lib/discordrb/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 0ec7e3a8b62b062f98fbee7d3df3f39bafdd67d9
|
4
|
+
data.tar.gz: e95a464d355afd62bb5efe8b05a1f8fd5fdc8f82
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: c0bcdf7cb78ea821c1216615ff3934e6d23839cf0ebee6f7ff06b812a18f250bc951777cfc3d5b8e3c5b30802ab553217c2f4438372012784f41526a3cb33c22
|
7
|
+
data.tar.gz: 851fe9fcb6fd6b1b1ae87f949956cf4708015f0afb76edda68eb528386b6d130cc8a8b31bf93fdf65853eacb91c91432a1e1bf06b88784147816902c30053e64
|
data/lib/discordrb/bot.rb
CHANGED
@@ -43,7 +43,7 @@ module Discordrb
|
|
43
43
|
while true do
|
44
44
|
@token = login
|
45
45
|
websocket_connect
|
46
|
-
puts "disconnected. attempting to reconnect. " + Time.now
|
46
|
+
puts "disconnected. attempting to reconnect. " + Time.now.to_s
|
47
47
|
sleep 2
|
48
48
|
end
|
49
49
|
end
|
@@ -145,7 +145,8 @@ module Discordrb
|
|
145
145
|
debug("Received token: #{login_response_object['token']}")
|
146
146
|
login_response_object['token']
|
147
147
|
rescue Exception => e
|
148
|
-
|
148
|
+
response_code = login_response.code || 0
|
149
|
+
if login_attempts < 100 && ( e.inspect.include?("No such host is known.") || response_code == 523)
|
149
150
|
sleep 15
|
150
151
|
puts "login failed. reattempting. " + Time.now.to_s
|
151
152
|
login_attempts = login_attempts + 1
|
data/lib/discordrb/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: discordrb
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.0.
|
4
|
+
version: 1.0.8
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- meew0
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2015-09-
|
11
|
+
date: 2015-09-23 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: faye-websocket
|