Skip to content

Commit afdc61e

Browse files
committed
[tools/rdfconverter] Get 'values' attribute
1 parent 8ea96a7 commit afdc61e

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

odml/tools/rdf_converter.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -127,8 +127,10 @@ def save_element(self, e, node=None):
127127
self.g.add((curr_node, fmt.rdf_map(k), node))
128128
self.save_element(p, node)
129129
elif isinstance(fmt, Property.__class__) and \
130-
k == 'value' and len(getattr(e, k)) > 0:
131-
values = getattr(e, k)
130+
k == 'value' and len(getattr(e, fmt.map(k))) > 0:
131+
# "value" needs to be mapped to its appropriate
132+
# Property library attribute.
133+
values = getattr(e, fmt.map(k))
132134
seq = URIRef(odmlns + unicode(uuid.uuid4()))
133135
self.g.add((seq, RDF.type, RDF.Seq))
134136
self.g.add((curr_node, fmt.rdf_map(k), seq))

0 commit comments

Comments
 (0)