Skip to content

Commit

Permalink
fix gh-proxy
Browse files Browse the repository at this point in the history
  • Loading branch information
stilleshan committed Feb 19, 2024
1 parent 8fb455d commit 619ef92
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions gh-proxy/app/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
stream_decode_response_unicode, iter_slices, CaseInsensitiveDict)
from urllib3.exceptions import (
DecodeError, ReadTimeoutError, ProtocolError)
from urllib.parse import quote

# config
# 分支文件使用jsDelivr镜像的开关,0为关闭,默认关闭
Expand Down Expand Up @@ -154,6 +155,7 @@ def handler(u):
if url.startswith('https:/') and not url.startswith('https://'):
url = 'https://' + url[7:]
return redirect(url)
u = quote(u, safe='/:')
return proxy(u)


Expand Down

0 comments on commit 619ef92

Please sign in to comment.