From 44b350e76de49495dae10a6c6e4fd899ec41166e Mon Sep 17 00:00:00 2001 From: Tony Mack <tmack@paris.CS.Princeton.EDU> Date: Sun, 1 Jul 2012 00:28:30 -0400 Subject: [PATCH] fix bug --- sfa/util/xrn.py | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/sfa/util/xrn.py b/sfa/util/xrn.py index af82adea..ff605714 100644 --- a/sfa/util/xrn.py +++ b/sfa/util/xrn.py @@ -223,7 +223,8 @@ class Xrn: raise SfaAPIError, "Xrn.hrn_to_urn, hrn=%s"%self.hrn if self.type and self.type.startswith('authority'): - self.authority = Xrn.hrn_split(self.hrn) + self.authority = Xrn.hrn_auth_list(self.hrn) + leaf = self.get_leaf() if not self.authority: self.authority = [self.hrn] type_parts = self.type.split("+") @@ -231,11 +232,11 @@ class Xrn: name = 'sa' if len(type_parts) > 1: name = type_parts[1] + authority_string = ":".join([self.get_authority_urn(), leaf]) else: self.authority = Xrn.hrn_auth_list(self.hrn) name = Xrn.hrn_leaf(self.hrn) - - authority_string = self.get_authority_urn() + authority_string = self.get_authority_urn() if self.type == None: urn = "+".join(['',authority_string,Xrn.unescape(name)]) -- 2.47.0