Skip to content

An open-source, privacy-first, self-hosted knowledge workspace where humans and AI agents work together 开源、隐私优先、自托管的知识工作空间,让人与智能体在此协作

:art: API `listDocsByPath` add an optional parameter `maxListCount` Fix https://github.com/siyuan-note/siyuan/issues/7993

Liang Dinge0b9002005f7
diff --git a/kernel/api/filetree.go b/kernel/api/filetree.go
index 4ecc3163f5..c130ccbb3d 100644
--- a/kernel/api/filetree.go
+++ b/kernel/api/filetree.go
@@ -624,7 +624,7 @@ func listDocsByPath(c *gin.Context) {
if arg["maxListCount"] != nil {
// API `listDocsByPath` add an optional parameter `maxListCount` https://github.com/siyuan-note/siyuan/issues/7993
maxListCount = int(arg["maxListCount"].(float64))
- if 0 == maxListCount {
+ if 0 >= maxListCount {
maxListCount = math.MaxInt
}
}