Skip to content

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
  • Loading branch information
simonsmh committed Jan 12, 2025
1 parent cab173a commit 5d27f59
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion biliparser/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ async def biliparser(urls) -> list[Video | Read | Audio | Live | Opus]:
headers=headers,
http2=True,
follow_redirects=True,
proxy=os.environ.get("FILE_PROXY", "HTTP_PROXY"),
proxy=os.environ.get("FILE_PROXY", os.environ.get("HTTP_PROXY")),
) as client:
tasks = list(
__feed_parser(
Expand Down
4 changes: 2 additions & 2 deletions biliparser/__main__.py
Original file line number Diff line number Diff line change
Expand Up @@ -205,7 +205,7 @@ def message_to_urls(update: Update, context: ContextTypes.DEFAULT_TYPE):

async def get_media_mediathumb_by_parser(f):
async with httpx.AsyncClient(
http2=True, follow_redirects=True, proxy=os.environ.get("FILE_PROXY", "HTTP_PROXY")
http2=True, follow_redirects=True, proxy=os.environ.get("FILE_PROXY", os.environ.get("HTTP_PROXY"))
) as client:
# Handle thumbnail
mediathumb = None
Expand Down Expand Up @@ -507,7 +507,7 @@ async def fetch(update: Update, context: ContextTypes.DEFAULT_TYPE) -> None:
async with httpx.AsyncClient(
http2=True,
follow_redirects=True,
proxy=os.environ.get("FILE_PROXY", "HTTP_PROXY"),
proxy=os.environ.get("FILE_PROXY", os.environ.get("HTTP_PROXY")),
) as client:
tasks = [
get_media(
Expand Down

0 comments on commit 5d27f59

Please sign in to comment.