ruby-bugzilla-nomagick 0.6.4.2 → 0.6.4.3

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
- SHA1:
3
- metadata.gz: 7d0144401728207724baa5368740e10be20df5c4
4
- data.tar.gz: a3e9670ef4959e2694f7e8d08348049817538512
2
+ SHA256:
3
+ metadata.gz: 3301157df4bb9b86f6e3e509c01cb894245f26376916b7dd1ce91aa7ad5ec867
4
+ data.tar.gz: 726dc6896243500d096c402f65f886017b1a997cdf65b6dbf44c6f5cc780c728
5
5
  SHA512:
6
- metadata.gz: a981499a89301c9329aeb5738d73dd270592d5690efe067cc65cbe31b7e03e1f452efc3759859ad98e97409d3d7168e1f3d46a174a1065f27f46d209fd4921d4
7
- data.tar.gz: 0d1bbc3d958490067f363a9262f6611b53648dbf7569f820665e9f4613b9a24ba2891c24e3c41460711bee4232752fc81996a02c065647a2cbb23f1d7a05652d
6
+ metadata.gz: 1fdeded76d88b6c84bf1f68ce0653f3a4bf86081b30f068d07c996f369266c65f8b591083aa881be58e34611b224b839f378bd450fe916a7aeedc63c407b6a4b
7
+ data.tar.gz: 177b36b071b3fb7f76a765baf5dbdc5785d63aaf4ba384feec3b5a86843d186d47e6ce042b396e6ea7d291c1467811a1b6905bf3844b07b7fc5b193c3f363e6b
data/lib/bugzilla/user.rb CHANGED
@@ -61,6 +61,9 @@ Keeps the bugzilla session during doing something in the block.
61
61
  else
62
62
  conf = {}
63
63
  end
64
+ if !val.nil? then
65
+ valid_login({'login'=>user, 'token'=>val}) or val = nil
66
+ end
64
67
  if !val.nil? then
65
68
  if key == :token then
66
69
  @iface.token = val
@@ -132,6 +135,16 @@ Raw Bugzilla API to log out the user.
132
135
 
133
136
  See http://www.bugzilla.org/docs/tip/en/html/api/Bugzilla/WebService/User.html
134
137
 
138
+ =end
139
+
140
+ =begin rdoc
141
+
142
+ ==== Bugzilla::User#valid_login(params)
143
+
144
+ Verify validity of a token for an user.
145
+
146
+ See http://www.bugzilla.org/docs/tip/en/html/api/Bugzilla/WebService/User.html
147
+
135
148
  =end
136
149
 
137
150
  protected
@@ -151,6 +164,11 @@ See http://www.bugzilla.org/docs/tip/en/html/api/Bugzilla/WebService/User.html
151
164
  @iface.call(cmd)
152
165
  end # def _logout
153
166
 
167
+ def _valid_login(cmd, *args)
168
+ raise ArgumentError, "Invalid parameters" unless args[0].kind_of?(Hash)
169
+ @iface.call(cmd, args[0])
170
+ end
171
+
154
172
  def __offer_account_by_email(cmd, *args)
155
173
  # FIXME
156
174
  end # def _offer_account_by_email
@@ -26,6 +26,6 @@
26
26
 
27
27
  module Bugzilla
28
28
 
29
- VERSION = "0.6.4.2"
29
+ VERSION = "0.6.4.3"
30
30
 
31
31
  end # module Bugzilla
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ruby-bugzilla-nomagick
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.6.4.2
4
+ version: 0.6.4.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Csaba Henk
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-08-08 00:00:00.000000000 Z
11
+ date: 2019-01-02 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rspec
@@ -98,7 +98,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
98
98
  version: 1.3.6
99
99
  requirements: []
100
100
  rubyforge_project:
101
- rubygems_version: 2.6.11
101
+ rubygems_version: 2.7.7
102
102
  signing_key:
103
103
  specification_version: 4
104
104
  summary: Ruby binding for Bugzilla WebService APIs