From bcbbb4305946f486f10c2e91b944ed9d3abbbbbc Mon Sep 17 00:00:00 2001 From: Liang Ding Date: Mon, 29 Aug 2022 20:18:35 +0800 Subject: [PATCH] =?UTF-8?q?:art:=20=E6=9F=A5=E6=89=BE=E6=9B=BF=E6=8D=A2?= =?UTF-8?q?=E6=94=AF=E6=8C=81=E6=9B=BF=E6=8D=A2=E8=B6=85=E9=93=BE=E6=8E=A5?= =?UTF-8?q?=E5=9C=B0=E5=9D=80=20Fix=20https://github.com/siyuan-note/siyua?= =?UTF-8?q?n/issues/5750?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- kernel/model/search.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/kernel/model/search.go b/kernel/model/search.go index 4b30e2160..f5ca2adcc 100644 --- a/kernel/model/search.go +++ b/kernel/model/search.go @@ -161,7 +161,7 @@ func FindReplace(keyword, replacement string, ids []string) (err error) { renameRootTitles[n.ID] = strings.ReplaceAll(title, keyword, replacement) renameRoots = append(renameRoots, n) } - case ast.NodeText, ast.NodeLinkText, ast.NodeLinkTitle, ast.NodeCodeSpanContent, ast.NodeCodeBlockCode, ast.NodeInlineMathContent, ast.NodeMathBlockContent: + case ast.NodeText, ast.NodeLinkDest, ast.NodeLinkText, ast.NodeLinkTitle, ast.NodeCodeSpanContent, ast.NodeCodeBlockCode, ast.NodeInlineMathContent, ast.NodeMathBlockContent: if bytes.Contains(n.Tokens, []byte(keyword)) { n.Tokens = bytes.ReplaceAll(n.Tokens, []byte(keyword), []byte(replacement)) }