lhs 19.8.0 → 19.8.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/lhs/concerns/record/request.rb +5 -1
- data/lib/lhs/version.rb +1 -1
- data/spec/option_blocks/main_spec.rb +9 -0
- 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: fec30fa29b9bf3d0d2f5540bc3b6ea7fa767bb79b4c30978b17b6e9e0f8b2caf
|
4
|
+
data.tar.gz: 0e6099e4312500c169520ac68de15b9ba59ce9f4d63678d17d1b89b678a4314e
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: b400501ee584f006e6c4c4795bbd26d2f2e52fab32babcb16e3cc3f29abd1fbaaa2aaab83c549b569fd58cf0d0f82562e538228ce58194c3125d6981f7ba9134
|
7
|
+
data.tar.gz: d3c117253aeb5118c84e79a91bec37e18cd1b15668a60d233b65b6c16a9a9b41d30f053050e290e0650c9ee1efa348d1cee575440b33959361649541a0300330
|
@@ -26,7 +26,11 @@ class LHS::Record
|
|
26
26
|
|
27
27
|
def deep_merge_with_option_blocks(options)
|
28
28
|
return options if LHS::OptionBlocks::CurrentOptionBlock.options.blank?
|
29
|
-
options.
|
29
|
+
if options.is_a?(Hash)
|
30
|
+
options.deep_merge(LHS::OptionBlocks::CurrentOptionBlock.options)
|
31
|
+
elsif options.is_a?(Array)
|
32
|
+
options.map { |option| option.deep_merge(LHS::OptionBlocks::CurrentOptionBlock.options) }
|
33
|
+
end
|
30
34
|
end
|
31
35
|
|
32
36
|
def single_request_load_and_merge_remaining_objects!(data, options, endpoint)
|
data/lib/lhs/version.rb
CHANGED
@@ -43,4 +43,13 @@ describe LHS::OptionBlocks do
|
|
43
43
|
expect(LHS::OptionBlocks::CurrentOptionBlock.options).to eq nil
|
44
44
|
end
|
45
45
|
end
|
46
|
+
|
47
|
+
context 'parallel requests' do
|
48
|
+
|
49
|
+
it 'does not fail merging option blocks for parallel requests' do
|
50
|
+
LHS.options(headers: { 'Tracking-Id': 1 }) do
|
51
|
+
Record.find(1234, 1234)
|
52
|
+
end
|
53
|
+
end
|
54
|
+
end
|
46
55
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: lhs
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 19.8.
|
4
|
+
version: 19.8.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- https://github.com/local-ch/lhs/graphs/contributors
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2019-07-
|
11
|
+
date: 2019-07-22 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: activemodel
|