uc3-dmp-dynamo 0.0.7 → 0.0.9
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/uc3-dmp-dynamo/client.rb +5 -3
- data/lib/uc3-dmp-dynamo/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 6b054d85d718d47e62a50c5f227d5442a4467d235da417491d05e2100c4750eb
|
4
|
+
data.tar.gz: 90e7d99d66f4bf219089c508b42cb7813d13f2d16cc8fd0fdb7662519234701f
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 7f1aaa39b77ec58b14b7c0b395bf19a11719afb08a12e42d7cf1358143206aad955cf78694033511d6ea810e0b738179415e1cd3f6c5b52dd59e0f964904c5aa
|
7
|
+
data.tar.gz: f16bba459f0226371303fb86132836c9576ad9af0b6224ecd18c19148b20cc301c9313f5a805d4674abc44f9de74e6f8dd1f8bb4f9dfd7340d4bb04304697cbe
|
@@ -72,11 +72,13 @@ module Uc3DmpDynamo
|
|
72
72
|
resp = @connection.query(hash)
|
73
73
|
# If debug is enabled then write the response to the LogWriter
|
74
74
|
if debug
|
75
|
-
puts "#{SOURCE} => query - args: #{hash}"
|
76
|
-
puts resp.items
|
75
|
+
puts "#{SOURCE} => query - args: #{hash.inspect}"
|
76
|
+
puts resp.items.inspect
|
77
77
|
end
|
78
|
+
return [] unless resp.items.any?
|
79
|
+
return resp.items if resp.items.first.is_a?(Hash)
|
78
80
|
|
79
|
-
resp.items
|
81
|
+
resp.items.first.respond_to?(:item) ? resp.items.map(&:item) : resp.items
|
80
82
|
rescue Aws::Errors::ServiceError => e
|
81
83
|
raise ClientError, format(MSG_DYNAMO_ERROR, msg: e.message, trace: e.backtrace)
|
82
84
|
end
|