mirror of
https://github.com/siyuan-note/siyuan.git
synced 2025-12-24 02:20:13 +01:00
This commit is contained in:
parent
a6008fbdac
commit
c957dfc6b2
1 changed files with 1 additions and 1 deletions
|
|
@ -342,6 +342,7 @@ func setLocalStorage(val interface{}) (err error) {
|
|||
}
|
||||
|
||||
func getLocalStorage() (ret map[string]interface{}, err error) {
|
||||
ret = map[string]interface{}{}
|
||||
lsPath := filepath.Join(util.DataDir, "storage/local.json")
|
||||
if !gulu.File.IsExist(lsPath) {
|
||||
return
|
||||
|
|
@ -353,7 +354,6 @@ func getLocalStorage() (ret map[string]interface{}, err error) {
|
|||
return
|
||||
}
|
||||
|
||||
ret = map[string]interface{}{}
|
||||
if err = gulu.JSON.UnmarshalJSON(data, &ret); nil != err {
|
||||
logging.LogErrorf("unmarshal storage [local] failed: %s", err)
|
||||
return
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue