Tweak media proxying
This commit is contained in:
parent
8613cc0206
commit
15ad5b08c4
2 changed files with 5 additions and 4 deletions
5
app.py
5
app.py
|
@ -236,8 +236,9 @@ def microblogpub_jsonld():
|
|||
)
|
||||
|
||||
|
||||
@app.route("/p/<path:url>")
|
||||
def proxy(url: str) -> Any:
|
||||
@app.route("/p/<scheme>/<path:url>")
|
||||
def proxy(scheme: str, url: str) -> Any:
|
||||
url = f"{scheme}://{url}"
|
||||
req_headers = {
|
||||
k: v
|
||||
for k, v in dict(request.headers).items()
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue