remove references to self.namespaces
[sfa.git] / sfa / methods / RenewSliver.py
index 5e3e266..6cbde77 100644 (file)
@@ -25,17 +25,17 @@ class RenewSliver(Method):
 
     def call(self, slice_xrn, creds, expiration_time, call_id=""):
 
-        self.api.logger.info("interface: %s\ttarget-hrn: %s\tcaller-creds: %s\tmethod-name: %s"%(self.api.interface, hrn, creds, self.name))
-
         (hrn, type) = urn_to_hrn(slice_xrn)
 
+        self.api.logger.info("interface: %s\ttarget-hrn: %s\tcaller-creds: %s\tmethod-name: %s"%(self.api.interface, hrn, creds, self.name))
+
         # Find the valid credentials
         valid_creds = self.api.auth.checkCredentials(creds, 'renewsliver', hrn)
 
         # Validate that the time does not go beyond the credential's expiration time
         requested_time = utcparse(expiration_time)
         if requested_time > Credential(string=valid_creds[0]).get_expiration():
-            raise InsufficientRights('SliverStatus: Credential expires before requested expiration time')
+            raise InsufficientRights('Renewsliver: Credential expires before requested expiration time')
         if requested_time > datetime.datetime.utcnow() + datetime.timedelta(days=60):
             raise Exception('Cannot renew > 60 days from now')
         manager = self.api.get_interface_manager()