go_to_webinar 0.2.7 → 0.2.9

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 51124acc18e98a3719106b3d55ac64a07185ba3cba1028a12deb3e2cb63b3527
4
- data.tar.gz: 0457ddd857fa3e9943240720df09f0c47a9b0b1d96d81de7981719c14f393a68
3
+ metadata.gz: cfea68fbffb7ce80a4db2f95e90e5ddfe2dcc60c3985799d50330df7cd4bbdf2
4
+ data.tar.gz: 6c83997291535d19f83cd04c5e95a00f4fc713d63bbb96e297885faf8f3e1159
5
5
  SHA512:
6
- metadata.gz: cb66bd8f0eb40dc6656f78ca397c2ffcae639c7c892aa15634fd7a9dc77db7c8076ed78abbaf44e5c28399e202e24ddc9cd6cf813b26c48634ed321d65a403c4
7
- data.tar.gz: 4ec82695f064d62fa481eb1241341958e281a90d19c696bd0084ede93fa0acaa7d583bdfc2feb714a87ae069fbd479b8539c9f991479d3d22b9cf754de78737b
6
+ metadata.gz: 89a7d3ba63a3a4f8e0b624b17e73edd921cf2032373eeab1e99b16fb307a40d514e1e8a258daacfa70dc929bb7da2eeeda07f0de67649ca42545e8a7b1687556
7
+ data.tar.gz: 49cc45452cbda420f495dd542dcbd62473f46ef44eaa4bcd7cb93d09b3992659cf03280fa607bcdfbc05a83669844442144c887cf1379e7cd62fe17d1c10c1f7
@@ -36,7 +36,7 @@ module GoToWebinar
36
36
  end
37
37
 
38
38
  def make_path(path)
39
- path = path.split(':organizer_key').join(organizer_key)
39
+ path = path.split(':organizer_key:').join(organizer_key)
40
40
  "#{url}#{path}"
41
41
  end
42
42
 
@@ -46,12 +46,17 @@ module GoToWebinar
46
46
  retries ||= 0
47
47
  yield
48
48
  rescue RestClient::Forbidden => e
49
- raise unless (retries += 1) < 2
50
- raise unless int_error_code(e) == 'InvalidToken'
51
- raise unless @g2w_oauth2_client&.access_token&.expired?
52
-
53
- @access_token = @g2w_oauth2_client.refresh_access_token.token
54
- retry
49
+ raise unless (retries += 1) <= 2
50
+
51
+ if retries < 2
52
+ raise unless int_error_code(e) == 'InvalidToken'
53
+ raise unless @g2w_oauth2_client&.access_token&.expired?
54
+ @access_token = @g2w_oauth2_client.refresh_access_token.token
55
+ retry
56
+ elsif retries == 3
57
+ @g2w_oauth2_client.get_new_access_token
58
+ retry
59
+ end
55
60
  end
56
61
 
57
62
  def int_error_code(exception)
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module GoToWebinar
4
- VERSION = '0.2.7'
4
+ VERSION = '0.2.9'
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: go_to_webinar
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.7
4
+ version: 0.2.9
5
5
  platform: ruby
6
6
  authors:
7
7
  - Danilo Jeremias da Silva
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: exe
11
11
  cert_chain: []
12
- date: 2020-03-23 00:00:00.000000000 Z
12
+ date: 2020-04-09 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: oauth2