🎨 优化同步日志

This commit is contained in:
Liang Ding 2022-07-28 10:52:29 +08:00
parent 10d61bb257
commit 297e40f628
No known key found for this signature in database
GPG key ID: 136F30F901A2231D
8 changed files with 22 additions and 20 deletions

View file

@ -465,7 +465,7 @@ func IndexRepo(memo string) (err error) {
return
}
func syncRepo(boot, exit, byHand bool) {
func syncRepo(boot, exit, byHand bool) (err error) {
if 1 > len(Conf.Repo.Key) {
syncDownloadErrCount++
planSyncAfter(fixSyncInterval)
@ -591,9 +591,9 @@ func indexRepoBeforeCloudSync(repo *dejavu.Repo) (index *entity.Index, err error
dejavu.CtxPushMsg: dejavu.CtxPushMsgToStatusBar,
})
if nil != err {
msg := fmt.Sprintf(Conf.Language(140), err)
msg := fmt.Sprintf(Conf.Language(140), formatErrorMsg(err))
util.PushStatusBar(msg)
util.PushErrMsg(msg, 5000)
util.PushErrMsg(msg, 12000)
logging.LogErrorf("index data repo before cloud sync failed: %s", err)
return
}