From e86b10ca5144de8d0d3ac3ebe0694509ec0d6903 Mon Sep 17 00:00:00 2001 From: ZiuChen <457353192@qq.com> Date: Sun, 18 Sep 2022 13:36:09 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E4=BF=AE=E6=AD=A3=E5=8C=B9=E9=85=8D?= =?UTF-8?q?=E5=9B=BE=E7=89=87=E6=96=87=E4=BB=B6=E7=9A=84=E6=AD=A3=E5=88=99?= =?UTF-8?q?=E8=A1=A8=E8=BE=BE=E5=BC=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/data/setting.json | 2 +- src/hooks/useClipOperate.js | 2 -- 2 files changed, 1 insertion(+), 3 deletions(-) diff --git a/src/data/setting.json b/src/data/setting.json index f7abdd1..00a2717 100644 --- a/src/data/setting.json +++ b/src/data/setting.json @@ -22,7 +22,7 @@ "id": "custom.1663468466", "title": "上传到图床", "icon": "🚀", - "match": ["image", { "type": "file", "regex": "/.*(jpg|png|jpeg|gif)$/i" }], + "match": ["image", { "type": "file", "regex": ".(?:jpg|jpeg|png)$" }], "command": "redirect:上传到图床" }, { diff --git a/src/hooks/useClipOperate.js b/src/hooks/useClipOperate.js index 0b73050..3915374 100644 --- a/src/hooks/useClipOperate.js +++ b/src/hooks/useClipOperate.js @@ -84,8 +84,6 @@ export default function useClipOperate({ emit }) { if (item.type === 'file') { const fl = JSON.parse(item.data) for (const f of fl) { - console.log(f.name, r.test(f.name)) - // TODO: fix: 图片文件不能正确匹配 if (r.test(f.name)) { return true }