🎨 OCR no longer blocks document loading https://github.com/siyuan-note/siyuan/issues/9230

This commit is contained in:
Daniel 2023-12-09 22:11:38 +08:00
parent 1dc5a371f6
commit aaf15c77e0
No known key found for this signature in database
GPG key ID: 86211BA83DF03017
4 changed files with 25 additions and 7 deletions

View file

@ -586,15 +586,13 @@ func NewLute() (ret *lute.Lute) {
return
}
var confSaveLock = sync.Mutex{}
func (conf *AppConf) Save() {
if util.ReadOnly {
return
}
confSaveLock.Lock()
defer confSaveLock.Unlock()
Conf.m.Lock()
defer Conf.m.Unlock()
newData, _ := gulu.JSON.MarshalIndentJSON(Conf, "", " ")
confPath := filepath.Join(util.ConfDir, "conf.json")