FIX the processing of the new linedump response format #3

This commit is contained in:
Caffeine Fueled 2025-10-17 23:22:08 +02:00
parent 028a41d86a
commit 6a4053f7e1
Signed by: cf7
GPG key ID: CA295D643074C68C

View file

@ -30,9 +30,9 @@ async def proxy_paste(paste_id: str):
headers={"Content-Type": "text/plain"}
)
dump_response.raise_for_status()
# linedump.com returns the full URL in the response body
dump_url = dump_response.text.strip()
# linedump.com returns the full URL in the first line of the response
dump_url = dump_response.text.strip().splitlines()[0]
# Redirect to the dump URL
return RedirectResponse(url=dump_url, status_code=302)