dmp-dynamo_adapter 0.2.5 → 0.2.6

Sign up to get free protection for your applications and to get access to all the features.
Files changed (3) hide show
  1. checksums.yaml +4 -4
  2. data/lib/dmp/dynamo_adapter.rb +1 -5
  3. metadata +1 -1
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: d0b673c5ab8af1a4ada8c4f14be3c2543c7af6e16ad3fbe34a31552451fea8a3
4
- data.tar.gz: 77484e5b3f58fd9088b635ab2e9fcd47b493aeb4fefc46618daec56a6dd993aa
3
+ metadata.gz: be57979b11b7ac8a35b820835768a0d3118b54dc82134ba099c24d338858d603
4
+ data.tar.gz: 4a4e3804862bce06a1aec7cf91b0b7164c2ad3a256ce4e57fb2a7e869dcdaaee
5
5
  SHA512:
6
- metadata.gz: b81abb15e34a2e6ca1d5dc0405b98bdae243b6099cca1f2c83735ea3b540c293059cb5d652d77095b899e2ac04b374f319dcdd6842f32a4b5dd76681b8bff083
7
- data.tar.gz: 29a757ae20c3888e0f9c5dd8fdd17b2b77b20c2af5c1b9c0a14e003bf55054d371c57a484730088d4d50decc5e95e9f090135070bc3a6d6d8f6df495bc4c5bf2
6
+ metadata.gz: 69d866715074b1b34444b30cc64489af45b10ca90f5aa27d079dba2f4bfac17feaac7e74fc60a8837465fb4a67c801dbdf762665d40408fd8938c204a53d2628
7
+ data.tar.gz: 53e24074d088a3d5a5d1232257679b6018a221d7c140fe5a91e012ba409d78383035e588e344fdcf5111bd970fe639851e785c32b170e348af15d02e0547bfe8
@@ -105,13 +105,9 @@ p "FINDING BY PK: PK - #{p_key.inspect} / SK - #{s_key.inspect}"
105
105
 
106
106
  # Try to find it first
107
107
  result = find_by_json(json: json)
108
-
109
- p "RESULT:"
110
- pp result
111
-
112
108
  return { status: 500, error: result.fetch(:error, MSG_DEFAULT) } if result[:status] == 500
113
109
  # Abort if found
114
- return { status: 400, error: MSG_EXISTS } if result[:items].any?
110
+ return { status: 400, error: MSG_EXISTS } if result.fetch(:items, []).any?
115
111
 
116
112
  # allocate a DMP ID
117
113
  p_key = Dmp::DmpIdHandler.preregister_dmp_id
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: dmp-dynamo_adapter
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.5
4
+ version: 0.2.6
5
5
  platform: ruby
6
6
  authors:
7
7
  - briri