Skip to content

Commit c34356d

Browse files
committed
Modified the rfc feed to better represent dois. Fixes ietf-tools#2014. Commit ready for merge.
- Legacy-Id: 12055
1 parent f6ffc1c commit c34356d

1 file changed

Lines changed: 4 additions & 1 deletion

File tree

ietf/doc/feeds.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -97,6 +97,8 @@ def add_item_elements(self, handler, item):
9797

9898
if 'doi' in item and item['doi'] is not None:
9999
handler.addQuickElement('dcterms:identifier',item['doi'],{'xsi:type':'dcterms:doi'})
100+
if 'doiuri' in item and item['doiuri'] is not None:
101+
handler.addQuickElement('dcterms:identifier',item['doiuri'],{'xsi:type':'dcterms:uri'})
100102

101103
if 'media_content' in item and item['media_content'] is not None:
102104
handler.startElement('media:content',{'url':item['media_content']['url'],'type':'text/plain'})
@@ -138,7 +140,8 @@ def item_extra_kwargs(self, item):
138140
'link_url': self.item_link(item)
139141
}
140142
})
141-
extra.update({'doi':'http://dx.doi.org/10.17487/%s' % item.canonical_name().upper()})
143+
extra.update({'doi':'10.17487/%s' % item.canonical_name().upper()})
144+
extra.update({'doiuri':'http://dx.doi.org/10.17487/%s' % item.canonical_name().upper()})
142145

143146
#TODO
144147
# R104 Publisher (Mandatory - but we need a string from them first)

0 commit comments

Comments
 (0)