[Python-modules-commits] [python-pyld] 89/276: Fix blank node check in _flatten.
Wolfgang Borgert
debacle at moszumanska.debian.org
Wed Oct 8 23:47:57 UTC 2014
This is an automated email from the git hooks/post-receive script.
debacle pushed a commit to branch master
in repository python-pyld.
commit 713d1a7104f55340dc6f2a90bfbff864989e69f4
Author: Dave Longley <dlongley at digitalbazaar.com>
Date: Mon May 21 15:51:06 2012 -0400
Fix blank node check in _flatten.
---
lib/pyld/jsonld.py | 7 ++++---
1 file changed, 4 insertions(+), 3 deletions(-)
diff --git a/lib/pyld/jsonld.py b/lib/pyld/jsonld.py
index 00f494c..50be27a 100644
--- a/lib/pyld/jsonld.py
+++ b/lib/pyld/jsonld.py
@@ -1976,9 +1976,10 @@ class JsonLdProcessor:
# handle embedded subject or subject reference
if _is_subject(o) or _is_subject_reference(o):
# rename blank node @id
- id = o.get('@id', '_:')
- if id.startswith('_:'):
- id = namer.get_name(id)
+ if _is_bnode(o):
+ id = namer.get_name(o.get('@id'))
+ else:
+ id = o['@id']
# add reference and recurse
JsonLdProcessor.add_value(
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/python-modules/packages/python-pyld.git
More information about the Python-modules-commits
mailing list