userlist 0.7.0 → 0.7.2

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: 8e20da18840923e5ac9df604853c38b2ffe949d3dea840eb6a9ff10889bb12b4
4
- data.tar.gz: eebd30d5ac3e947cdddc60200666e6912e467940e534c6c1e9c80d1995f309b0
3
+ metadata.gz: ee5f47b48e2bcc0babdbb7bcc85e84e5b197dacefb777eb19764d6f23e78e682
4
+ data.tar.gz: 53caac6db3e462e9fe280541a7249da39e821a6a8bed7c70373131bebe9a6e19
5
5
  SHA512:
6
- metadata.gz: 3dbc899903623868bb8b595f02cf38949de23260756134a80c94518dbae826ffdd41ea2c3895201e42e96827f4152157c3518ffee00cd9528e675d2adb1788c0
7
- data.tar.gz: 76e7cbd7847f1b5d48468529314198fa813df674bbc40d4d4eaa41f6269b54234bd9be6c850b291ab12250e5b9da8b26082a07b7511d3956c3c96ffde757e996
6
+ metadata.gz: 687b4ff1d89c5c98814fc89fe7cb8097577bd0cea63138f40e194eb47d6d6a2807b624c9dd15f2b64868f0473f1baaf268b6f7cb3945b713c20d00150b71739c
7
+ data.tar.gz: 0b72bc8a28a6cba596c5afaff369e62b26cc8a84347f0059f68859c02df270562663c9e7faa8ddbb89a7053cf6d811d7dfcafa75f2f9233c27a36aebd72e4b4a
data/.rspec CHANGED
@@ -1,2 +1,4 @@
1
1
  --format documentation
2
+ --require spec_helper
3
+ --order random
2
4
  --color
@@ -57,6 +57,7 @@ module Userlist
57
57
 
58
58
  logger.debug "Sending #{request.method} to #{URI.join(endpoint, request.path)} with body #{request.body}"
59
59
 
60
+ http.start unless http.started?
60
61
  http.request(request)
61
62
  end
62
63
 
@@ -11,7 +11,11 @@ module Userlist
11
11
  end
12
12
 
13
13
  def call(*args)
14
- ::Sidekiq::Client.push(default_options.merge(options).merge('args' => args))
14
+ payload = default_options
15
+ .merge(options)
16
+ .merge('args' => normalize(args))
17
+
18
+ ::Sidekiq::Client.push(payload)
15
19
  end
16
20
 
17
21
  private
@@ -31,6 +35,10 @@ module Userlist
31
35
  'queue' => 'default'
32
36
  }
33
37
  end
38
+
39
+ def normalize(args)
40
+ JSON.parse(JSON.generate(args))
41
+ end
34
42
  end
35
43
  end
36
44
  end
@@ -1,3 +1,3 @@
1
1
  module Userlist
2
- VERSION = '0.7.0'.freeze
2
+ VERSION = '0.7.2'.freeze
3
3
  end
data/lib/userlist.rb CHANGED
@@ -51,6 +51,10 @@ module Userlist
51
51
  yield config
52
52
  end
53
53
 
54
+ def reset!
55
+ @config = nil
56
+ end
57
+
54
58
  attr_writer :logger
55
59
  end
56
60
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: userlist
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.7.0
4
+ version: 0.7.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Benedikt Deicke
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2022-02-02 00:00:00.000000000 Z
11
+ date: 2022-10-20 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -149,7 +149,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
149
149
  - !ruby/object:Gem::Version
150
150
  version: '0'
151
151
  requirements: []
152
- rubygems_version: 3.2.32
152
+ rubygems_version: 3.3.7
153
153
  signing_key:
154
154
  specification_version: 4
155
155
  summary: Ruby wrapper for the Userlist API