X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=sfa%2Futil%2Fnamespace.py;h=45ce06a751012ea18d6d4ae8a977d7f92e9ca713;hb=0bf44636d2555b909a9929dd91222f1234c6bb0e;hp=d2006e50b729782d81e0c7fe4a51d59b6667c95c;hpb=927fcb2064c193487c280b40c6003e7ae3268e18;p=sfa.git 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])