mirror of
https://github.com/siyuan-note/siyuan.git
synced 2025-12-16 22:50:13 +01:00
🎨 虚拟引用不再缓存关键字 Fix https://github.com/siyuan-note/siyuan/issues/6602
This commit is contained in:
parent
ed58765121
commit
30e58a474d
3 changed files with 0 additions and 30 deletions
|
|
@ -70,29 +70,6 @@ func removeBlockCache(id string) {
|
|||
removeRefCacheByDefID(id)
|
||||
}
|
||||
|
||||
func getVirtualRefKeywordsCache() ([]string, bool) {
|
||||
if disabled {
|
||||
return nil, false
|
||||
}
|
||||
|
||||
if val, ok := memCache.Get("virtual_ref"); ok {
|
||||
return val.([]string), true
|
||||
}
|
||||
return nil, false
|
||||
}
|
||||
|
||||
func setVirtualRefKeywords(keywords []string) {
|
||||
if disabled {
|
||||
return
|
||||
}
|
||||
|
||||
memCache.Set("virtual_ref", keywords, 1)
|
||||
}
|
||||
|
||||
func ClearVirtualRefKeywords() {
|
||||
memCache.Del("virtual_ref")
|
||||
}
|
||||
|
||||
var defIDRefsCache = gcache.New(30*time.Minute, 5*time.Minute) // [defBlockID]map[refBlockID]*Ref
|
||||
|
||||
func GetRefsCacheByDefID(defID string) (ret []*Ref) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue