fix missing import
[sfa.git] / geni / util / api.py
index b8cb3c2..bf5d4f7 100644 (file)
@@ -14,6 +14,7 @@ from geni.util.faults import *
 from geni.util.debug import *
 from geni.util.rights import *
 from geni.util.credential import *
+from geni.util.misc import *
 
 # See "2.2 Characters" in the XML specification:
 #
@@ -120,7 +121,7 @@ class GeniAPI:
     def getPLCShell(self):
         self.plauth = {'Username': self.config.GENI_PLC_USER,
                          'AuthMethod': 'password',
-                         'AuthString': self.config.GENI_PLC_PASSWORD} 
+                         'AuthString': self.config.GENI_PLC_PASSWORD}
         try:
             import PLC.Shell
             shell = PLC.Shell.Shell(globals = globals())
@@ -155,8 +156,8 @@ class GeniAPI:
             credential = Credential(filename = cred_filename)
             return credential
         except IOError:
-            from geni.util.registry import Registries
-            registries = Registries()
+            from geni.registry import Registries
+            registries = Registries(self)
             registry = registries[self.hrn] 
             self_cred = registry.get_credential(None, type, self.hrn)
             cred = registry.get_credential(self_cred, type, self.hrn)