gitlab 4.16.0 → 4.16.1
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/gitlab/client/users.rb +7 -2
- data/lib/gitlab/objectified_hash.rb +8 -1
- data/lib/gitlab/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: 797a89bf7bdc146d8381fcf6a6bada7909b70d694f5b9b5c4a7781c69396a6d7
|
4
|
+
data.tar.gz: d564a8c8d0840f7ed4517f39d17b8a9a8138079b1fbbc7b9576de4b7159626e0
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: abb59a55e8a113155818e1531bb4c22578b27a520ac1bea7d9f932a49c8d7be8c0ee4d3e3f42cc5ee870a143553aae3192dc693c7ad8c74b2d7079c6c85cb94e
|
7
|
+
data.tar.gz: c48dc657cf576f747c8a1153114b72681a4c6a5285259a7ef0534a8afdd85c67907dca98c63c1d6450d7766c9692879365b0411985574a570ce209b533a90a91
|
data/lib/gitlab/client/users.rb
CHANGED
@@ -239,10 +239,15 @@ class Gitlab::Client
|
|
239
239
|
#
|
240
240
|
# @param [String] email Email address
|
241
241
|
# @param [Integer] user_id The ID of a user.
|
242
|
+
# @param [Boolean] skip_confirmation Skip confirmation and assume e-mail is verified
|
242
243
|
# @return [Gitlab::ObjectifiedHash]
|
243
|
-
def add_email(email, user_id = nil)
|
244
|
+
def add_email(email, user_id = nil, skip_confirmation = nil)
|
244
245
|
url = user_id.to_i.zero? ? '/user/emails' : "/users/#{user_id}/emails"
|
245
|
-
|
246
|
+
if skip_confirmation.nil?
|
247
|
+
post(url, body: { email: email })
|
248
|
+
else
|
249
|
+
post(url, body: { email: email, skip_confirmation: skip_confirmation })
|
250
|
+
end
|
246
251
|
end
|
247
252
|
|
248
253
|
# Delete email
|
@@ -34,7 +34,14 @@ module Gitlab
|
|
34
34
|
|
35
35
|
# Respond to messages for which `self.data` has a key
|
36
36
|
def method_missing(method_name, *args, &block)
|
37
|
-
data.key?(method_name.to_s)
|
37
|
+
if data.key?(method_name.to_s)
|
38
|
+
data[method_name.to_s]
|
39
|
+
elsif data.respond_to?(method_name)
|
40
|
+
warn 'WARNING: Please convert ObjectifiedHash object to hash before calling Hash methods on it.'
|
41
|
+
data.send(method_name, *args, &block)
|
42
|
+
else
|
43
|
+
super
|
44
|
+
end
|
38
45
|
end
|
39
46
|
|
40
47
|
def respond_to_missing?(method_name, include_private = false)
|
data/lib/gitlab/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: gitlab
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 4.16.
|
4
|
+
version: 4.16.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Nihad Abbasov
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: exe
|
11
11
|
cert_chain: []
|
12
|
-
date: 2020-07-
|
12
|
+
date: 2020-07-12 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: httparty
|