From 8037b635baa53ebcf82c42593fa2a54c279f67a7 Mon Sep 17 00:00:00 2001 From: BTMuli Date: Fri, 10 Nov 2023 00:46:42 +0800 Subject: [PATCH] =?UTF-8?q?=F0=9F=91=BD=EF=B8=8F=20=E9=80=82=E5=BA=94=20en?= =?UTF-8?q?dpoint=20=E5=8F=98=E6=9B=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/web/request/getGachaLog.ts | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/src/web/request/getGachaLog.ts b/src/web/request/getGachaLog.ts index e2240d2a..28835c08 100644 --- a/src/web/request/getGachaLog.ts +++ b/src/web/request/getGachaLog.ts @@ -1,14 +1,14 @@ /** * @file web/request/getGachaLog.ts * @description 获取抽卡记录请求函数 - * @since Beta v0.3.0 + * @since Beta v0.3.5 */ import { http } from "@tauri-apps/api"; /** * @description 获取抽卡记录 - * @since Beta v0.3.0 + * @since Beta v0.3.5 * @param {string} authkey authkey * @param {string} gachaType 抽卡类型 * @param {string} endId 结束 id,默认为 0 @@ -19,7 +19,7 @@ export async function getGachaLog( gachaType: string, endId: string = "0", ): Promise { - const url = "https://hk4e-api.mihoyo.com/event/gacha_info/api/getGachaLog"; + const url = "https://public-operation-hk4e.mihoyo.com/gacha_info/api/getGachaLog"; const params = { lang: "zh-cn", auth_appid: "webview_gacha", @@ -36,7 +36,7 @@ export async function getGachaLog( query: params, }) .then((res) => { - if (res.data.retcode === 0) return res.data.data.list; - return res.data; + if (res.data.retcode !== 0) return res.data; + return res.data.data.list; }); }