mirror of
https://github.com/siyuan-note/siyuan.git
synced 2026-01-04 15:58:49 +01:00
Merge remote-tracking branch 'origin/dev' into dev
This commit is contained in:
commit
cd4764a123
5 changed files with 18 additions and 12 deletions
10
app/stage/protyle/js/lute/lute.min.js
vendored
10
app/stage/protyle/js/lute/lute.min.js
vendored
File diff suppressed because one or more lines are too long
|
|
@ -9,7 +9,7 @@ require (
|
|||
github.com/88250/clipboard v0.1.5
|
||||
github.com/88250/epub v0.0.0-20230830085737-c19055cd1f48
|
||||
github.com/88250/gulu v1.2.3-0.20231023172823-f152fc5d93ef
|
||||
github.com/88250/lute v1.7.6-0.20231117014702-f00e74ce2d3d
|
||||
github.com/88250/lute v1.7.6-0.20231117124256-a3955cb3899d
|
||||
github.com/88250/pdfcpu v0.3.14-0.20230401044135-c7369a99720c
|
||||
github.com/88250/vitess-sqlparser v0.0.0-20210205111146-56a2ded2aba1
|
||||
github.com/ClarkThan/ahocorasick v0.0.0-20231011042242-30d1ef1347f4
|
||||
|
|
|
|||
|
|
@ -10,8 +10,8 @@ github.com/88250/go-sqlite3 v1.14.13-0.20220714142610-fbbda1ee84f5 h1:8HdZozCsXS
|
|||
github.com/88250/go-sqlite3 v1.14.13-0.20220714142610-fbbda1ee84f5/go.mod h1:NyWgC/yNuGj7Q9rpYnZvas74GogHl5/Z4A/KQRfk6bU=
|
||||
github.com/88250/gulu v1.2.3-0.20231023172823-f152fc5d93ef h1:LVJO3aj18v63T2whGGt3gL5imkJk+7ujPfFv38X7Oi8=
|
||||
github.com/88250/gulu v1.2.3-0.20231023172823-f152fc5d93ef/go.mod h1:pTWnjt+6qUqNnP9xltswsJxgCBVu3C7eW09u48LWX0k=
|
||||
github.com/88250/lute v1.7.6-0.20231117014702-f00e74ce2d3d h1:G9x/Jj0X/sSx2236+Q0QVjNoR3sSO9SQDQwvWTO8e8E=
|
||||
github.com/88250/lute v1.7.6-0.20231117014702-f00e74ce2d3d/go.mod h1:+wUqx/1kdFDbWtxn9LYJlaCOAeol2pjSO6w+WJTVQsg=
|
||||
github.com/88250/lute v1.7.6-0.20231117124256-a3955cb3899d h1:6JBd1WREdFkZqVclm0VioBfDcswVB6RFn2HRBCssTN8=
|
||||
github.com/88250/lute v1.7.6-0.20231117124256-a3955cb3899d/go.mod h1:+wUqx/1kdFDbWtxn9LYJlaCOAeol2pjSO6w+WJTVQsg=
|
||||
github.com/88250/pdfcpu v0.3.14-0.20230401044135-c7369a99720c h1:Dl/8S9iLyPMTElnWIBxmjaLiWrkI5P4a21ivwAn5pU0=
|
||||
github.com/88250/pdfcpu v0.3.14-0.20230401044135-c7369a99720c/go.mod h1:S5YT38L/GCjVjmB4PB84PymA1qfopjEhfhTNQilLpv4=
|
||||
github.com/88250/vitess-sqlparser v0.0.0-20210205111146-56a2ded2aba1 h1:48T899JQDwyyRu9yXHePYlPdHtpJfrJEUGBMH3SMBWY=
|
||||
|
|
|
|||
|
|
@ -46,7 +46,7 @@ func queryAssetContentRawStmt(stmt string, limit int) (ret []map[string]interfac
|
|||
return
|
||||
}
|
||||
|
||||
noLimit := !strings.Contains(strings.ToLower(stmt), " limit ")
|
||||
noLimit := !containsLimitClause(stmt)
|
||||
var count, errCount int
|
||||
for rows.Next() {
|
||||
columns := make([]interface{}, len(cols))
|
||||
|
|
@ -152,7 +152,7 @@ func selectAssetContentsRawStmt(stmt string, limit int) (ret []*AssetContent) {
|
|||
}
|
||||
defer rows.Close()
|
||||
|
||||
noLimit := !strings.Contains(strings.ToLower(stmt), " limit ")
|
||||
noLimit := !containsLimitClause(stmt)
|
||||
var count, errCount int
|
||||
for rows.Next() {
|
||||
count++
|
||||
|
|
|
|||
|
|
@ -503,7 +503,7 @@ func queryRawStmt(stmt string, limit int) (ret []map[string]interface{}, err err
|
|||
return
|
||||
}
|
||||
|
||||
noLimit := !strings.Contains(strings.ToLower(stmt), " limit ")
|
||||
noLimit := !containsLimitClause(stmt)
|
||||
var count, errCount int
|
||||
for rows.Next() {
|
||||
columns := make([]interface{}, len(cols))
|
||||
|
|
@ -609,7 +609,7 @@ func selectBlocksRawStmt(stmt string, limit int) (ret []*Block) {
|
|||
}
|
||||
defer rows.Close()
|
||||
|
||||
noLimit := !strings.Contains(strings.ToLower(stmt), " limit ")
|
||||
noLimit := !containsLimitClause(stmt)
|
||||
var count, errCount int
|
||||
for rows.Next() {
|
||||
count++
|
||||
|
|
@ -836,3 +836,9 @@ func GetContainerText(container *ast.Node) string {
|
|||
})
|
||||
return buf.String()
|
||||
}
|
||||
|
||||
func containsLimitClause(stmt string) bool {
|
||||
return strings.Contains(strings.ToLower(stmt), " limit ") ||
|
||||
strings.Contains(strings.ToLower(stmt), "\nlimit ") ||
|
||||
strings.Contains(strings.ToLower(stmt), "\tlimit ")
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue