Skip to content

Commit bc3419d

Browse files
committed
fix: 修复没有 token 的问题
1 parent 068be51 commit bc3419d

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

core/cluster.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -359,6 +359,7 @@ async def download(self, filelist: set[File]):
359359
config.const.base_url,
360360
headers={
361361
"User-Agent": USER_AGENT,
362+
"Authorization": f"Bearer {await clusters.clusters[0].get_token()}"
362363
}
363364
)
364365
sessions.append(session)
@@ -462,6 +463,7 @@ async def _r(urls: tuple[URLResponse, ...]):
462463
config.const.base_url,
463464
headers={
464465
"User-Agent": USER_AGENT,
466+
"Authorization": f"Bearer {await clusters.clusters[0].get_token()}"
465467
}
466468
) as session:
467469
await asyncio.gather(*[_r(urls) for urls in urls])

0 commit comments

Comments
 (0)