✨ Support for searching asset content https://github.com/siyuan-note/siyuan/issues/8874
This commit is contained in:
parent
cc7d431d26
commit
29678939f3
1 changed files with 4 additions and 0 deletions
|
@ -282,6 +282,8 @@ func buildAssetContentOrderBy(orderBy int) string {
|
|||
var assetContentSearcher = NewAssetsSearcher()
|
||||
|
||||
func IndexAssetContent(absPath string) {
|
||||
defer logging.Recover()
|
||||
|
||||
assetsDir := util.GetDataAssetsAbsPath()
|
||||
|
||||
ext := strings.ToLower(filepath.Ext(absPath))
|
||||
|
@ -353,6 +355,8 @@ type AssetsSearcher struct {
|
|||
}
|
||||
|
||||
func (searcher *AssetsSearcher) FullIndex() {
|
||||
defer logging.Recover()
|
||||
|
||||
assetsDir := util.GetDataAssetsAbsPath()
|
||||
if !gulu.File.IsDir(assetsDir) {
|
||||
return
|
||||
|
|
Loading…
Add table
Reference in a new issue