From 0bf44636d2555b909a9929dd91222f1234c6bb0e Mon Sep 17 00:00:00 2001 From: Josh Karlin Date: Thu, 22 Apr 2010 21:54:47 +0000 Subject: [PATCH 1/1] Updating hrn_to_urn --- sfa/util/namespace.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/sfa/util/namespace.py b/sfa/util/namespace.py index d2006e50..45ce06a7 100644 --- a/sfa/util/namespace.py +++ b/sfa/util/namespace.py @@ -91,7 +91,11 @@ def hrn_to_urn(hrn, type=None): name = get_leaf(hrn) if authority.startswith("plc"): - urn = "+".join(['',authority.replace('.',':'),type,name]) + if type == None: + urn = "+".join(['',authority.replace('.',':'),name]) + else: + urn = "+".join(['',authority.replace('.',':'),type,name]) + else: urn = "+".join(['',authority,type,name]) -- 2.43.0