[web/views/rdf] Take the second element of XY equivalent for non final relation
When given a Yams snippet of the form `<etype> <rtype>` ``xy.xeq()`` will
return the XML snippet equivalent to this relation in the form of a tuple
`(subject, rtype, object)` so ``item`` will always be a tuple here.
In fact, the correct code appears just a few lines above (around line 88) for
final relations so I guess this is a copy-paste mistake.
Closes #4745929.
--- a/web/views/rdf.py Wed Feb 11 12:42:19 2015 +0100
+++ b/web/views/rdf.py Fri Mar 13 14:47:35 2015 +0100
@@ -94,7 +94,7 @@
add( (cwuri, CW[rtype], URIRef(related.cwuri)) )
try:
for item in xy.xeq('%s %s' % (entity.e_schema.type, rtype)):
- add( (cwuri, urijoin(item), URIRef(related.cwuri)) )
+ add( (cwuri, urijoin(item[1]), URIRef(related.cwuri)) )
except xy.UnsupportedVocabulary:
pass
else: