nm-gigya 0.1.4 → 0.1.5

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: dd469ea919cff4b4266c2108262ffe6389cbd567
4
- data.tar.gz: deaf04fc37d1eab826428a2a803613853425751c
3
+ metadata.gz: 4fcc3079f011c2bc7f89f096c5cbb4396fd64c07
4
+ data.tar.gz: 7d91e181820f5e382fe48acf76eb7bf68e6a3ab9
5
5
  SHA512:
6
- metadata.gz: 551115a424bf3beffb3a455d9343df7a179d419e1876bc47b0459d9221330ab16f45175a0cb334b743be90ada602055e212162be401669c37601871dbe40e4cb
7
- data.tar.gz: 06e816c219ced927f348eed631daf2253799f6aca11d36195914393eaa60ed1c7ea47336f34c140effdd9baabaf654ef2805d2ba04e07b7d91319c3f0da0cc72
6
+ metadata.gz: ff759dd6c05e0101ba0b68931d2f4c9ced35b54e1362e6d830445c67a418fad72d40ae8eb5ffb92c958b08052e52773a0360219681e33439fcac13eba3138295
7
+ data.tar.gz: 74a89c4aba86b37f741094adf3bb1cdfb3bbd6993ccb9f4e35a5b854385a40c7f1b5bc4cc56b36e73357daa1337acfdba445c16d09ec4c0a3990b819b72a9700
@@ -161,7 +161,8 @@ module Gigya
161
161
  :datacenter => ENV["GIGYA_DATACENTER"] || "us1",
162
162
  :api_key => ENV["GIGYA_API_KEY"],
163
163
  :user_key => ENV["GIGYA_USER_KEY"],
164
- :user_secret => ENV["GIGYA_USER_SECRET"]
164
+ :user_secret => ENV["GIGYA_USER_SECRET"],
165
+ :debug_connection => ENV["GIGYA_DEBUG_CONNECTION"] == "1"
165
166
  )
166
167
  conn.jwt_skip_validation = false
167
168
  conn
@@ -222,7 +223,7 @@ module Gigya
222
223
  def build_test_jwt(uid = nil, data_options = {}, expiration = nil, gigya_munge = false)
223
224
  data_options = (data_options || {}).dup
224
225
  data_options["sub"] = uid unless uid.nil?
225
- data_options["sub"] ||=SecureRandom.uuid
226
+ data_options["sub"] ||= SecureRandom.uuid
226
227
  data_options["apiKey"] ||= (@opts[:api_key] || "no_api_key")
227
228
  data_options["iss"] ||= "https://fidm.gigya.com/jwt/#{data_options["apiKey"]}/"
228
229
  data_options["iat"] ||= (Time.now - 10.seconds).to_i
data/lib/gigya/user.rb CHANGED
@@ -3,6 +3,15 @@ module Gigya
3
3
  attr_accessor :gigya_details
4
4
  attr_accessor :gigya_connection
5
5
 
6
+ @@extra_profile_fields = []
7
+ def self.extra_profile_fields=(val)
8
+ @@extra_profile_fields = val
9
+ end
10
+
11
+ def self.extra_profile_fields
12
+ @@extra_profile_fields
13
+ end
14
+
6
15
  @@default_gigya_user_class = nil
7
16
  def self.default_gigya_user_class
8
17
  @@default_gigya_user_class
@@ -42,7 +51,7 @@ module Gigya
42
51
 
43
52
  def reload
44
53
  conn = gigya_connection || Gigya::Connection.shared_connection
45
- set_attributes(conn.api_get("accounts", "getAccountInfo", {UID: uid}))
54
+ set_attributes(conn.api_get("accounts", "getAccountInfo", {UID: uid, include:"profile,data,subscriptions,userInfo,preferences", extraProfileFields:@@extra_profile_fields.join(",")}))
46
55
  end
47
56
 
48
57
  def save
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.1.4
4
+ version: 0.1.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - Jonathan Bartlett
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2018-08-15 00:00:00.000000000 Z
12
+ date: 2018-10-04 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: httparty