Skip to content

Commit

Permalink
Fix fallback build number retrieval again (#628)
Browse files Browse the repository at this point in the history
  • Loading branch information
edpowers authored Dec 17, 2023
1 parent 4076a3b commit cf97a1d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion discord/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -1477,7 +1477,7 @@ async def _get_build_number(session: ClientSession) -> int: # Thank you Discord
try:
login_page_request = await session.get('https://discord.com/login', timeout=7)
login_page = await login_page_request.text()
build_url = 'https://discord.com/assets/' + re.compile(r'assets/+([a-z0-9]+)\.js').findall(login_page)[-2] + '.js'
build_url = 'https://discord.com/assets/' + re.compile(r'assets/+([a-z.0-9]+)\.js').findall(login_page)[-2] + '.js'
build_request = await session.get(build_url, timeout=7)
build_file = await build_request.text()
build_find = re.findall(r'Build Number:\D+"(\d+)"', build_file)
Expand Down

0 comments on commit cf97a1d

Please sign in to comment.