Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions traject_config_eac_cpf.rb
Original file line number Diff line number Diff line change
Expand Up @@ -215,7 +215,7 @@
relations = record.xpath('//eac:cpfDescription/eac:relations/eac:cpfRelation', EAC_NS)
relations.each do |rel|
# Get the related entity href/identifier
href = rel['href'] || rel['xlink:href']
href = rel['href'] || rel.attribute_with_ns('href', 'http://www.w3.org/1999/xlink')&.value
relation_type = rel['cpfRelationType']

if href
Expand All @@ -233,7 +233,7 @@
to_field 'related_agent_uris_ssim' do |record, accumulator|
relations = record.xpath('//eac:cpfDescription/eac:relations/eac:cpfRelation', EAC_NS)
relations.each do |rel|
href = rel['href'] || rel['xlink:href']
href = rel['href'] || rel.attribute_with_ns('href', 'http://www.w3.org/1999/xlink')&.value
accumulator << href if href
end
end
Expand Down