Don't give error on shutdown

This commit is contained in:
Ruud
2012-01-14 17:58:10 +01:00
parent 1a9d15ecc2
commit 45db5dc447
+10 -2
View File
@@ -42,10 +42,18 @@ class Core(Plugin):
})
def crappyShutdown(self):
self.urlopen('%sapp.shutdown' % self.createApiUrl())
try:
self.urlopen('%sapp.shutdown' % self.createApiUrl(), show_error = False)
return True
except:
return False
def crappyRestart(self):
self.urlopen('%sapp.restart' % self.createApiUrl())
try:
self.urlopen('%sapp.restart' % self.createApiUrl(), show_error = False)
return True
except:
return False
def shutdown(self):
self.initShutdown()