From 81478ba67f26fb07216b1c6013067f77659ebade Mon Sep 17 00:00:00 2001 From: Yufan Sheng Date: Sun, 23 Jun 2024 23:12:57 +0800 Subject: [PATCH] chore: remove the uneed console.log. --- src/components/comment/artalk.ts | 4 ++-- src/components/player/resolver.ts | 2 +- src/pages/avatar/[hash].png.ts | 1 - 3 files changed, 3 insertions(+), 4 deletions(-) diff --git a/src/components/comment/artalk.ts b/src/components/comment/artalk.ts index 318ec47..a5e3445 100644 --- a/src/components/comment/artalk.ts +++ b/src/components/comment/artalk.ts @@ -26,7 +26,7 @@ export const loadComments = async (key: string, title: string | null, offset: nu const data = await fetch(urlJoin(server, `/api/v2/comments?${querystring.stringify(params)}`)) .then((response) => response.json()) .catch((e) => { - console.log(e); + console.error(e); return null; }); @@ -44,7 +44,7 @@ export const createComment = async (req: CommentReq): Promise { - console.log(e); + console.error(e); return null; }); diff --git a/src/components/player/resolver.ts b/src/components/player/resolver.ts index 9f42bc0..a102210 100644 --- a/src/components/player/resolver.ts +++ b/src/components/player/resolver.ts @@ -24,7 +24,7 @@ const song = async (props: MusicPlayerProps): Promise => { const data = await fetch(`https://api.injahow.cn/meting/?type=song&id=${netease}`) .then((response) => response.json()) .catch((e) => { - console.log(e); + console.error(e); return [emptySong]; }); diff --git a/src/pages/avatar/[hash].png.ts b/src/pages/avatar/[hash].png.ts index ef510ba..45d3138 100644 --- a/src/pages/avatar/[hash].png.ts +++ b/src/pages/avatar/[hash].png.ts @@ -16,7 +16,6 @@ const avatarImage = async (hash: string): Promise => { options.settings.comments.avatar.mirror, `${hash}.png?s=${options.settings.comments.avatar.size}&d=${defaultAvatar()}`, ); - console.log(link); return new Response(Buffer.from(await (await fetch(link)).arrayBuffer()), { headers: { 'Content-Type': 'image/png' }, });