uc3-dmp-id 0.0.99 → 0.0.100

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
2
  SHA256:
3
- metadata.gz: e3bcba612098c1d0acd9a553f25549a198bbefb0f28c9c0ef166038382c17c07
4
- data.tar.gz: 5ba9be2055b9c39a4c887930b5250860cd9dc986ddf4d0248d25e786f932c9fe
3
+ metadata.gz: 980cf55dcebe87df7656894c5322def896fc16863fc8e1bb4d5a2c3f44c289df
4
+ data.tar.gz: 94dd8f43a9dc1108fe030f6651ea858f3445d6f27a42ba7f448fe4c311b180cd
5
5
  SHA512:
6
- metadata.gz: f3b3e728a5c532fb024dddd69a366fc9867e3a05856562c863b89059a38a320d63e70b9d0241249b2a8d419bf8898e894bd93617c681b3601ea82e701433f558
7
- data.tar.gz: 5401aba365595519141ea7f2115366bdaf53b47183ee2fcd3ecba219c9625f8148cc1042faa8f67737f4fb750d60dfe62d2a334ed8e7449a02b8edbd2023744f
6
+ metadata.gz: 1c54010fb9da4a20dd0604f7a88105aa79cb7129f8167abee1fd61d8bd1ea5a0186e721eab95cc46d71b227bd7faf8f98174bc91813f5cfac5a052cdb7956f75
7
+ data.tar.gz: 7033cdaf7cddb6dcfe307fd33117e472fe69068d23b34b545cca023452382da953c73ed7f4c525e3ff7e07400d3df0eaeeafb3db3742f98a2941877d6ca80df6
@@ -30,8 +30,13 @@ module Uc3DmpId
30
30
  # Splice together assertions made while the user was updating the DMP ID
31
31
  def splice(latest_version:, modified_version:, logger: nil)
32
32
  # Return the modified_version if the timestamps are the same (meaning no new assertions were made while the
33
- # user was working on the DMP ID)
34
- return modified_version if latest_version['dmphub_updated_at'] == modified_version['dmphub_updated_at']
33
+ # user was working on the DMP ID) OR neither version has assertions
34
+ return modified_version if latest_version['dmphub_updated_at'] == modified_version['dmphub_updated_at'] ||
35
+ (latest_version.fetch('dmphub_assertions', []).empty? &&
36
+ modified_version.fetch('dmphub_assertions', []).empty?)
37
+
38
+ puts "LATEST_VERSION ASSERTIONS: #{latest_version['dmphub_assertions']}"
39
+ puts "MODIFIED_VERSION ASSERTIONS: #{modified_version['dmphub_assertions']}"
35
40
 
36
41
  # Clone any existing assertions on the current DMP ID so we can manipulate them
37
42
  existing_assertions = Helper.deep_copy_dmp(obj: latest_version.fetch('dmphub_assertions', []))
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Uc3DmpId
4
- VERSION = '0.0.99'
4
+ VERSION = '0.0.100'
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: uc3-dmp-id
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.99
4
+ version: 0.0.100
5
5
  platform: ruby
6
6
  authors:
7
7
  - Brian Riley