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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: f2b9aba77d10f1d0b341c8e8f7c9e8c5a25de3ad
4
- data.tar.gz: 49a423d60940fbcdef970ef097fab403a9eb581d
3
+ metadata.gz: 0ec7e3a8b62b062f98fbee7d3df3f39bafdd67d9
4
+ data.tar.gz: e95a464d355afd62bb5efe8b05a1f8fd5fdc8f82
5
5
  SHA512:
6
- metadata.gz: 83b12c85e6b6362e91f81b287dcf1df3a12a421c96f9be0dda091f6ae2e1b9cf0188518a56c5b7bce0c4b1321695ce1df7dfa1f01f3de642d8769ddcb8da914e
7
- data.tar.gz: 08e3f4188e7380e189756af5f97e848059d53a15c1c24a2d327d96ab61694620a03dfc70b1f04ad85855428c9bf10be5d13eabeda47673a8e7f3c27d2802c44d
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
- if login_attempts < 100 && ( e.inspect.include?("No such host is known.") || login_response.code == 523)
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
@@ -1,3 +1,5 @@
1
+ require 'active_support/core_ext/module'
2
+
1
3
  module Discordrb::Events
2
4
  class Negated
3
5
  attr_reader :object
@@ -1,3 +1,3 @@
1
1
  module Discordrb
2
- VERSION = "1.0.7"
2
+ VERSION = "1.0.8"
3
3
  end
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.7
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-13 00:00:00.000000000 Z
11
+ date: 2015-09-23 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: faye-websocket