nm-gigya 0.0.5 → 0.0.6

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
  SHA1:
3
- metadata.gz: 54ddacd5192e1bde544288bd6751384422487ee5
4
- data.tar.gz: 0ae9c210941b1765ea64caf22fc22841d5a52eef
3
+ metadata.gz: c2600b2a029001bec188706347f7c8040b08fc2a
4
+ data.tar.gz: ac59bf9c2b25c1864a24c6e247eb574552894a75
5
5
  SHA512:
6
- metadata.gz: 25f6b600005ff095766ad5da26af0aa1bc70c164c0de7a62e145a013806c387e46b40a11889a28d84cdc80e1fce41d5e7bd3a25db82cbb734b06e726d44f86d1
7
- data.tar.gz: bd13e0a4fd14127c32c57253ec9d8ebc5887e0000f6c44a264f473cef783432e6493ae0d5194004f03495aca4f5a9e627781b3cc6ee4834824eaa63f18e90433
6
+ metadata.gz: 9a63c574d1ef8960248a6b6f70c61f9f823f511e48d74aaa72971eeae497332c92e6e3fd5cc9a9ca32076cb14b9a42ac05822969976066b44126ae2f39ffe36a
7
+ data.tar.gz: 97de7e9ba5310350fed94c43151e7e9e869627d71df1642c75280fd055f1758ba167f747a8b794e4e8a2ac2344b348ad5dc0329fb9cc604e2a46493da2c3790b
@@ -16,9 +16,16 @@ module Gigya
16
16
  def interpret_jwt_token
17
17
  @gigya_token ||= begin
18
18
  tmp_token = nil
19
- authenticate_with_http_token do |token, options|
20
- tmp_token = token
19
+
20
+ begin
21
+ authenticate_with_http_token do |token, options|
22
+ tmp_token = token
23
+ end
24
+ rescue
25
+ # If this is being called from a helper instead of a controller, then the authenticate_with_http_token is not available.
26
+ # Additionally, we probably can't even use the HTTP Authorization header anyway
21
27
  end
28
+
22
29
  tmp_token = params[GIGYA_QUERY_PARAM] unless params[GIGYA_QUERY_PARAM].blank?
23
30
  if tmp_token.blank?
24
31
  tmp_token = cookies[GIGYA_COOKIE_PARAM]
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: nm-gigya
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.5
4
+ version: 0.0.6
5
5
  platform: ruby
6
6
  authors:
7
7
  - Jonathan Bartlett