main
bashrc 2026-08-01 14:51:32 +01:00
parent 25e535ba24
commit 54e831ffb1
1 changed files with 4 additions and 4 deletions

View File

@ -2425,7 +2425,7 @@ class JsonLdProcessor(object):
nil = graph_object[RDF_NIL] nil = graph_object[RDF_NIL]
for usage in nil['usages']: for usage in nil['usages']:
node = usage['node'] node = usage['node']
property = usage['property'] property2 = usage['property']
head = usage['value'] head = usage['value']
list_ = [] list_ = []
list_nodes = [] list_nodes = []
@ -2437,7 +2437,7 @@ class JsonLdProcessor(object):
# 4. Have no keys other than: @id, rdf:first, rdf:rest # 4. Have no keys other than: @id, rdf:first, rdf:rest
# and, optionally, @type where the value is rdf:List. # and, optionally, @type where the value is rdf:List.
node_key_count = len(node.keys()) node_key_count = len(node.keys())
while (property == RDF_REST and while (property2 == RDF_REST and
_is_object(referenced_once.get(node['@id'])) and _is_object(referenced_once.get(node['@id'])) and
_is_array(node[RDF_FIRST]) and _is_array(node[RDF_FIRST]) and
len(node[RDF_FIRST]) == 1 and len(node[RDF_FIRST]) == 1 and
@ -2454,7 +2454,7 @@ class JsonLdProcessor(object):
# get next node, moving backwards through list # get next node, moving backwards through list
usage = referenced_once[node['@id']] usage = referenced_once[node['@id']]
node = usage['node'] node = usage['node']
property = usage['property'] property2 = usage['property']
head = usage['value'] head = usage['value']
node_key_count = len(node.keys()) node_key_count = len(node.keys())
@ -2463,7 +2463,7 @@ class JsonLdProcessor(object):
break break
# the list is nested in another list # the list is nested in another list
if property == RDF_FIRST: if property2 == RDF_FIRST:
# empty list # empty list
if node['@id'] == RDF_NIL: if node['@id'] == RDF_NIL:
# can't convert rdf:nil to a @list object because it # can't convert rdf:nil to a @list object because it