cul_hydra 1.4.4 → 1.4.5

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
  SHA1:
3
- metadata.gz: ec361540642c4b017b3de3a596e5b535da517e37
4
- data.tar.gz: b90682e644091e10d12c9fbe56f3643a22033d5a
3
+ metadata.gz: dcda7a0da76912ed7cb8076e50676d89227bf760
4
+ data.tar.gz: bab55b31de7128a4f10611cdda2d1504c8a6e298
5
5
  SHA512:
6
- metadata.gz: 0d90087ef8440fb86acf4f1abf737722b8073171b5ef61b8f5ee4e428bb19080411a8a47b478d313307d6038cd44276175a466894bd599253f4d43b8b9a4712a
7
- data.tar.gz: 8b701785ed90406501d6208cdefb7189a04bce0ed8646b2f5dfe00e5182f3bad1245bdd871abcc91a08c077283e49b4d4e3e5db39f16abb5b152707abedb432c
6
+ metadata.gz: 401b8f79ba092a3fa0d4b835af8a3cf77a7dc794e7b16f5cd1dce4ec10f6357d2577d4e985214cfb4d6c537b62a15784871303fca891eec5a43c8bf646d02415
7
+ data.tar.gz: 34c5ac78e8e86dd4aa390a7665098c024b6a8d739cfb4915f8ccdee91cad3e317cc068f59f183c1655eed9f18081bfba5f4119c7670988bcbad7b92bfe28765e
@@ -49,13 +49,20 @@ class Concept < GenericAggregator
49
49
  end
50
50
 
51
51
  def description=(value)
52
- value = '' if value.nil?
53
52
  ds = description_ds
54
- if ds
55
- ds.content = value
53
+ if value.nil? || value.empty?
54
+ if ds
55
+ # Datastreams don't allow empty content, so we need to delete the datastream
56
+ datastreams['descriptionText'].delete
57
+ clear_relationship(:description)
58
+ end
56
59
  else
57
- add_relationship(:description, internal_uri.to_s + "/descriptionText")
58
- datastreams['descriptionText'].content = value
60
+ if ds
61
+ ds.content = value
62
+ else
63
+ add_relationship(:description, internal_uri.to_s + "/descriptionText")
64
+ datastreams['descriptionText'].content = value
65
+ end
59
66
  end
60
67
  end
61
68
 
@@ -1,6 +1,6 @@
1
1
  module Cul
2
2
  module Hydra
3
- VERSION = '1.4.4'
3
+ VERSION = '1.4.5'
4
4
  def self.version
5
5
  VERSION
6
6
  end
@@ -1,6 +1,6 @@
1
1
  module Cul
2
2
  module Hydra
3
- VERSION = '1.4.3'
3
+ VERSION = '1.4.4'
4
4
  def self.version
5
5
  VERSION
6
6
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: cul_hydra
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.4.4
4
+ version: 1.4.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - Benjamin Armintor