mirror of
https://github.com/siyuan-note/siyuan.git
synced 2025-12-16 22:50:13 +01:00
🐛 Regular expression search does not work with single quotes https://github.com/siyuan-note/siyuan/issues/14940
This commit is contained in:
parent
572baa99bd
commit
669b2884b1
1 changed files with 1 additions and 0 deletions
|
|
@ -1900,6 +1900,7 @@ func maxContent(content string, maxLen int) string {
|
|||
}
|
||||
|
||||
func fieldRegexp(regexp string) string {
|
||||
regexp = strings.ReplaceAll(regexp, "'", "''") // 不需要转义双引号,因为条件都是通过单引号包裹的,只需要转义单引号即可
|
||||
buf := bytes.Buffer{}
|
||||
buf.WriteString("(")
|
||||
buf.WriteString("content REGEXP '")
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue