infinum_id 1.5.1 → 1.6.0

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
  SHA256:
3
- metadata.gz: 0d9fdcc2c9dfa8896896f7f3f9f9bccb49d1df43288b9d182e539d1e1e1b43e8
4
- data.tar.gz: 367748cbcf9c54c24e71bab2fcd0d052c889be8540a4666bac98dc29f799ada8
3
+ metadata.gz: 54ff7ee267e4f9e1da3da96046a0eea0bf9e78997190ef664dffbf67c97e7d8d
4
+ data.tar.gz: 2c24ab2ccc749c10dfc86a07499b228c8415780f15f797f9504df5d1f2ba12bf
5
5
  SHA512:
6
- metadata.gz: 783ac8ebf1218077b419e1853bd498846c8eef05ea8359ea096bf66f7f611c341331101a44b139776bba64d208c4c4e913c6e543cbb655a17235f98e81180365
7
- data.tar.gz: 70e5ff6d55531db42ed33345ba00814a857a8fdfd38cd4adbba683ed428eba0566ac157c6e616ad4fbd491fa178d0a83fbace669a7a3d619549280ce5291ceba
6
+ metadata.gz: 0bbca07deacd0194746befd4746c93b409027f07c5d4c7e06c734cc23b5a43c6466fe06d653d9f581b372fb77f9445876c8ee45f2367a2f8d236d6e84bdce4ae
7
+ data.tar.gz: 879c2d2b3ff00844d92f8569bd230fb6892f6833926ca9203b553cee8fdbf8154387ac92e6aa40d36c5d3c9d3b643302c42f76f9792fa814d7c4093baa43ff2c
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- infinum_id (1.5.1)
4
+ infinum_id (1.6.0)
5
5
  blueprinter
6
6
  bundler
7
7
  devise
@@ -58,7 +58,7 @@ GEM
58
58
  public_suffix (>= 2.0.2, < 4.0)
59
59
  arel (9.0.0)
60
60
  bcrypt (3.1.13)
61
- blueprinter (0.22.0)
61
+ blueprinter (0.23.0)
62
62
  builder (3.2.3)
63
63
  byebug (10.0.2)
64
64
  coderay (1.1.2)
@@ -76,11 +76,13 @@ GEM
76
76
  docile (1.3.1)
77
77
  domain_name (0.5.20190701)
78
78
  unf (>= 0.0.5, < 1.0.0)
79
- dry-configurable (0.9.0)
79
+ dry-configurable (0.11.1)
80
80
  concurrent-ruby (~> 1.0)
81
81
  dry-core (~> 0.4, >= 0.4.7)
82
+ dry-equalizer (~> 0.2)
82
83
  dry-core (0.4.9)
83
84
  concurrent-ruby (~> 1.0)
85
+ dry-equalizer (0.3.0)
84
86
  erubi (1.8.0)
85
87
  factory_bot (5.0.0)
86
88
  activesupport (>= 4.2.0)
@@ -91,7 +93,7 @@ GEM
91
93
  i18n (>= 0.7)
92
94
  faraday (1.0.0)
93
95
  multipart-post (>= 1.2, < 3)
94
- ffi (1.11.3)
96
+ ffi (1.12.2)
95
97
  ffi-compiler (1.0.1)
96
98
  ffi (>= 1.0.0)
97
99
  rake
@@ -131,7 +133,7 @@ GEM
131
133
  nio4r (2.3.1)
132
134
  nokogiri (1.10.1)
133
135
  mini_portile2 (~> 2.4.0)
134
- oauth2 (1.4.2)
136
+ oauth2 (1.4.4)
135
137
  faraday (>= 0.8, < 2.0)
136
138
  jwt (>= 1.0, < 3.0)
137
139
  multi_json (~> 1.3)
data/README.md CHANGED
@@ -79,7 +79,7 @@ Devise is used like middleware for authentication that uses Omniauth with infinu
79
79
  InfinumId.configure do |config|
80
80
  config.service_name = 'Revisor'
81
81
  config.resource_name = 'User'
82
- config.infinum_id_send_email = !Rails.env.test? # to disable in tests
82
+ config.send_invite_request = !Rails.env.test? # to disable in tests
83
83
  config.resource_attributes = [:uid, :email, :first_name, :last_name, :deactivated_at, :time_zone, :avatar_url, :slack_username]
84
84
  end
85
85
  ```
@@ -26,7 +26,9 @@ module InfinumId
26
26
  end
27
27
 
28
28
  def resource
29
- @resource ||= resource_class.find_by(uid: user_params[:uid])
29
+ @resource ||=
30
+ resource_class.find_by(uid: user_params[:uid], provider: params[:provider]) ||
31
+ resource_class.find_by(email: user_params[:email])
30
32
  end
31
33
 
32
34
  def render_not_found
@@ -1,3 +1,3 @@
1
1
  module InfinumId
2
- VERSION = '1.5.1'
2
+ VERSION = '1.6.0'
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: infinum_id
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.5.1
4
+ version: 1.6.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Dajana Jeroncic
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2020-01-15 00:00:00.000000000 Z
11
+ date: 2020-02-20 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler