Signed-off-by: Daniel <845765@qq.com>
This commit is contained in:
Daniel
2026-05-31 22:11:20 +08:00
parent 186f0b4c13
commit 2f0fcb7bb4
2 changed files with 4 additions and 4 deletions

View File

@@ -44,7 +44,7 @@ var refBacklinksCmd = &cobra.Command{
keyword, _ := cmd.Flags().GetString("keyword")
sortMode, _ := cmd.Flags().GetInt("sort")
_, backlinks, _, count, _ := model.GetBacklink2(id, keyword, "", sortMode, 0, false)
_, backlinks, _, count, _ := model.GetBacklink2(id, keyword, "", sortMode, 0, model.Conf.Editor.BacklinkContainChildren)
switch outputFormat {
case "json":
@@ -71,7 +71,7 @@ var refMentionsCmd = &cobra.Command{
keyword, _ := cmd.Flags().GetString("keyword")
sortMode, _ := cmd.Flags().GetInt("sort")
_, _, backmentions, _, count := model.GetBacklink2(id, "", keyword, 0, sortMode, false)
_, _, backmentions, _, count := model.GetBacklink2(id, "", keyword, 0, sortMode, model.Conf.Editor.BacklinkContainChildren)
switch outputFormat {
case "json":

View File

@@ -62,7 +62,7 @@ func refBacklinks(args map[string]interface{}) (CallToolResult, error) {
id, _ := args["id"].(string)
keyword, _ := args["keyword"].(string)
_, backlinks, _, _, _ := model.GetBacklink2(id, keyword, "", 0, 0, false)
_, backlinks, _, _, _ := model.GetBacklink2(id, keyword, "", 0, 0, model.Conf.Editor.BacklinkContainChildren)
if len(backlinks) == 0 {
return CallToolResult{Content: []ContentItem{{Type: "text", Text: "no backlinks found"}}}, nil
}
@@ -79,7 +79,7 @@ func refMentions(args map[string]interface{}) (CallToolResult, error) {
id, _ := args["id"].(string)
keyword, _ := args["keyword"].(string)
_, _, mentions, _, _ := model.GetBacklink2(id, "", keyword, 0, 0, false)
_, _, mentions, _, _ := model.GetBacklink2(id, "", keyword, 0, 0, model.Conf.Editor.BacklinkContainChildren)
if len(mentions) == 0 {
return CallToolResult{Content: []ContentItem{{Type: "text", Text: "no mentions found"}}}, nil
}