mirror of
https://github.com/HelloZeroNet/ZeroNet.git
synced 2023-12-14 04:33:03 +01:00
Always verify client update
This commit is contained in:
parent
718a00974b
commit
c7078be407
1 changed files with 13 additions and 5 deletions
|
@ -1095,11 +1095,19 @@ class UiWebsocket(object):
|
|||
self.response(to, "ok")
|
||||
|
||||
def actionServerUpdate(self, to):
|
||||
self.cmd("updating")
|
||||
sys.modules["main"].update_after_shutdown = True
|
||||
SiteManager.site_manager.save()
|
||||
sys.modules["main"].file_server.stop()
|
||||
sys.modules["main"].ui_server.stop()
|
||||
def cbServerUpdate(res):
|
||||
self.response(to, "ok")
|
||||
self.cmd("updating")
|
||||
sys.modules["main"].update_after_shutdown = True
|
||||
SiteManager.site_manager.save()
|
||||
sys.modules["main"].file_server.stop()
|
||||
sys.modules["main"].ui_server.stop()
|
||||
|
||||
self.cmd(
|
||||
"confirm",
|
||||
[_["Update <b>ZeroNet client</b> to latest version?"], _["Update"]],
|
||||
cbServerUpdate
|
||||
)
|
||||
|
||||
def actionServerPortcheck(self, to):
|
||||
file_server = sys.modules["main"].file_server
|
||||
|
|
Loading…
Reference in a new issue