gds-api-adapters 76.0.0 → 77.0.0
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 +4 -4
- data/lib/gds_api/account_api.rb +1 -5
- data/lib/gds_api/test_helpers/account_api.rb +2 -4
- data/lib/gds_api/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 2ea534ae361e87fde66ed0a9909c3920b0a58c86ad5e26b3dd4c7d13baabe15c
|
4
|
+
data.tar.gz: a24876d1c08767f5d934e9327feb212a6e35f33142c4c6764e85f28eca525de5
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 23a867c3eb864e2078989ac9f395d572a3679a06ad1efc20f080563d4aabd65e46e27b29118e77daa130924d00c9de4c6f7a7a4f1131d2b242099dc3a05783d6
|
7
|
+
data.tar.gz: 2340a2464e1971055760d1169f05e18c40e9ef50e75610b763f6c6018fcae863a8669aa77a8c9aedaa9ed3632c8e463f0147b92a80d2a811c69d2f4b1ec47a94
|
data/lib/gds_api/account_api.rb
CHANGED
@@ -75,16 +75,12 @@ class GdsApi::AccountApi < GdsApi::Base
|
|
75
75
|
# @param [String] subject_identifier The identifier of the user, shared between the auth service and GOV.UK.
|
76
76
|
# @param [String, nil] email The user's current email address
|
77
77
|
# @param [Boolean, nil] email_verified Whether the user's current email address is verified
|
78
|
-
# @param [Boolean, nil] cookie_consent Whether the user has consented to analytics cookies
|
79
|
-
# @param [Boolean, nil] feedback_consent Whether the user has consented to being contacted for feedback
|
80
78
|
#
|
81
79
|
# @return [Hash] The user's subject identifier and email attributes
|
82
|
-
def update_user_by_subject_identifier(subject_identifier:, email: nil, email_verified: nil
|
80
|
+
def update_user_by_subject_identifier(subject_identifier:, email: nil, email_verified: nil)
|
83
81
|
params = {
|
84
82
|
email: email,
|
85
83
|
email_verified: email_verified,
|
86
|
-
cookie_consent: cookie_consent,
|
87
|
-
feedback_consent: feedback_consent,
|
88
84
|
}.compact
|
89
85
|
|
90
86
|
patch_json("#{endpoint}/api/oidc-users/#{subject_identifier}", params)
|
@@ -159,17 +159,15 @@ module GdsApi
|
|
159
159
|
###########################################
|
160
160
|
# PATCH /api/oidc-users/:subject_identifier
|
161
161
|
###########################################
|
162
|
-
def stub_update_user_by_subject_identifier(subject_identifier:, email: nil, email_verified: nil,
|
162
|
+
def stub_update_user_by_subject_identifier(subject_identifier:, email: nil, email_verified: nil, old_email: nil, old_email_verified: nil)
|
163
163
|
stub_account_api_request(
|
164
164
|
:patch,
|
165
165
|
"/api/oidc-users/#{subject_identifier}",
|
166
|
-
with: { body: hash_including({ email: email, email_verified: email_verified
|
166
|
+
with: { body: hash_including({ email: email, email_verified: email_verified }.compact) },
|
167
167
|
response_body: {
|
168
168
|
sub: subject_identifier,
|
169
169
|
email: email || old_email,
|
170
170
|
email_verified: email_verified || old_email_verified,
|
171
|
-
cookie_consent: cookie_consent || old_cookie_consent,
|
172
|
-
feedback_consent: feedback_consent || old_feedback_consent,
|
173
171
|
},
|
174
172
|
)
|
175
173
|
end
|
data/lib/gds_api/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: gds-api-adapters
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version:
|
4
|
+
version: 77.0.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- GOV.UK Dev
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2021-12-
|
11
|
+
date: 2021-12-10 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: addressable
|