Avoid a second remctl to determine whether ice3 is up
[invirt/packages/invirt-web.git] / code / main.py
index 60c2818..c7dff0e 100755 (executable)
@@ -203,7 +203,7 @@ def getListDict(user):
     has_vnc = {}
     xmlist = g.xmlist
     checkpoint.checkpoint('Got uptimes')
-    can_clone = (controls.getList([Machine.get_by(name='ice3')])) == {}
+    can_clone = 'ice3' in g.xmlist_raw
     for m in machines:
         if m not in xmlist:
             has_vnc[m] = 'Off'