From 13e618075b61c6a7207f98b68f52e024837125f3 Mon Sep 17 00:00:00 2001 From: Daniel <845765@qq.com> Date: Thu, 19 Jun 2025 10:35:32 +0800 Subject: [PATCH] :art: Clean code https://github.com/siyuan-note/siyuan/pull/15087 --- kernel/api/extension.go | 3 --- 1 file changed, 3 deletions(-) diff --git a/kernel/api/extension.go b/kernel/api/extension.go index 97fa3e3cd..d249bb73b 100644 --- a/kernel/api/extension.go +++ b/kernel/api/extension.go @@ -62,10 +62,8 @@ func extensionCopy(c *gin.Context) { clippingSym := false symArticleHref := "" - hasHref := nil != form.Value["href"] isPartClip := nil != form.Value["clipType"] && form.Value["clipType"][0] == "part" - if hasHref && !isPartClip { // 剪藏链滴帖子时直接使用 Markdown 接口的返回 // https://ld246.com/article/raw/1724850322251 @@ -82,7 +80,6 @@ func extensionCopy(c *gin.Context) { if "" != baseURL { articleID := strings.TrimPrefix(symArticleHref, originalPrefix) - if idx := strings.IndexAny(articleID, "/?#"); -1 != idx { articleID = articleID[:idx] }