🎨 清理云端同步目录推送消息

This commit is contained in:
Liang Ding 2022-07-21 14:56:07 +08:00
parent 4e634097d9
commit 9945660afa
No known key found for this signature in database
GPG key ID: 136F30F901A2231D

View file

@ -255,6 +255,8 @@ func CreateCloudSyncDir(name string) (err error) {
}
func RemoveCloudSyncDir(name string) (err error) {
msgId := util.PushMsg(Conf.Language(116), 15000)
syncLock.Lock()
defer syncLock.Unlock()
@ -270,9 +272,11 @@ func RemoveCloudSyncDir(name string) (err error) {
err = dejavu.RemoveCloudRepo(name, cloudInfo)
if nil != err {
util.PushUpdateMsg(msgId, formatErrorMsg(err), 5000)
return
}
util.PushClearMsg(msgId)
if Conf.Sync.CloudName == name {
Conf.Sync.CloudName = "main"
Conf.Save()