mirror of
https://github.com/ankitects/anki.git
synced 2025-11-09 14:17:13 -05:00
catch upgraderequired response
This commit is contained in:
parent
2e233fb86f
commit
8fd920fce1
1 changed files with 3 additions and 0 deletions
|
|
@ -573,6 +573,9 @@ class FullSyncer(HttpSyncer):
|
||||||
self.col.close()
|
self.col.close()
|
||||||
cont = self.req("download")
|
cont = self.req("download")
|
||||||
tpath = self.col.path + ".tmp"
|
tpath = self.col.path + ".tmp"
|
||||||
|
if cont == "upgradeRequired":
|
||||||
|
runHook("sync", "upgradeRequired")
|
||||||
|
return
|
||||||
open(tpath, "wb").write(cont)
|
open(tpath, "wb").write(cont)
|
||||||
# check the received file is ok
|
# check the received file is ok
|
||||||
d = DB(tpath)
|
d = DB(tpath)
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue