Skip to content

Commit

Permalink
fix: api url changed (#71)
Browse files Browse the repository at this point in the history
  • Loading branch information
biuuu committed Aug 1, 2024
1 parent 60bc7b4 commit 9dab8bd
Show file tree
Hide file tree
Showing 3 changed files with 2,008 additions and 2,205 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "star-rail-warp-export",
"version": "0.1.7",
"version": "0.1.8",
"main": "./dist/electron/main/main.js",
"author": "biuuu <https://github.com/biuuu>",
"homepage": "https://github.com/biuuu/star-rail-warp-export",
Expand Down
5 changes: 3 additions & 2 deletions src/main/getData.js
Original file line number Diff line number Diff line change
Expand Up @@ -289,9 +289,9 @@ const getQuerystring = (url) => {
const text = i18n.log
const { searchParams, host } = new URL(fixAuthkey(url))
if (host.includes('webstatic-sea') || host.includes('hkrpg-api-os') || host.includes('api-os-takumi') || host.includes('hoyoverse.com')) {
apiDomain = 'https://api-os-takumi.mihoyo.com'
apiDomain = 'https://public-operation-hkrpg-sg.hoyoverse.com'
} else {
apiDomain = 'https://api-takumi.mihoyo.com'
apiDomain = 'https://public-operation-hkrpg.mihoyo.com'
}
const authkey = searchParams.get('authkey')
if (!authkey) {
Expand Down Expand Up @@ -417,6 +417,7 @@ const fetchData = async (urlOverride) => {
let originTimeZone = ''
for (const type of gachaType) {
const { list, uid, region, region_time_zone } = await getGachaLogs(type, queryString)
await sleep(0.3)
const logs = list.map((item) => {
const { id, item_id, item_type, name, rank_type, time, gacha_id, gacha_type } = item
return { id, item_id, item_type, name, rank_type, time, gacha_id, gacha_type }
Expand Down
Loading

0 comments on commit 9dab8bd

Please sign in to comment.