Import OgLinuxOperations only when necessary

This fixes a circular import error produced by the import of ogClient inside of
OgLinuxOperations.
more_events
Roberto Hueso Gómez 2020-06-08 13:39:48 +02:00 committed by OpenGnSys Support Team
parent 1377aceec2
commit 93bbc39d4b
1 changed files with 1 additions and 2 deletions

View File

@ -18,8 +18,6 @@ import signal
from src.restRequest import *
from src.linux.ogOperations import OgLinuxOperations
class ThreadState(Enum):
IDLE = 0
BUSY = 1
@ -239,6 +237,7 @@ class ogRest():
self.samba_config = self.CONFIG['samba']
if self.mode == 'live':
from src.linux.ogOperations import OgLinuxOperations
self.operations = OgLinuxOperations(self.CONFIG)
elif self.mode == 'virtual':
from src.virtual.ogOperations import \