Update server.py

This commit is contained in:
Nova Cat 2025-01-13 20:30:59 -08:00
parent e7a5ccf74f
commit 5e019d6daf

View file

@ -72,7 +72,7 @@ def relay():
if i.split(" ")[0][0] == "3":
return redirect("/gem?gemini=" + quote(i.split(" ")[1][9:], safe=''))
elif i.split(" ")[0][0] == "1":
return f'<!DOCTYPE html>\n<html><head><meta charset="UTF-8"><link rel="stylesheet" href="/style.css"><title>Input required</title></head><body><h1>Input required</h1><p>The specified Gemini server wants more data: "<pre>{i}</pre>"</p><br><form action="/gem"><input hidden class="input" value="{url}" type="text" name="gemini"><input hidden class="input" type="text" name="query"><br><input type="submit" class="go" value="Go!"><br></form></body></html>'
return f'<!DOCTYPE html>\n<html><head><meta charset="UTF-8"><link rel="stylesheet" href="/style.css"><title>Input required</title></head><body><h1>Input required</h1><p>The specified Gemini server wants more data: "<pre>{i}</pre>"</p><br><form action="/gem"><input hidden class="input" value="{url}" type="text" name="gemini"><input class="input" type="text" name="query"><br><input type="submit" class="go" value="Go!"><br></form></body></html>'
elif i.split(" ")[0][0] != "2":
return f'<!DOCTYPE html>\n<html><head><meta charset="UTF-8"><link rel="stylesheet" href="/style.css"><title>Something went wrong...</title></head><body><h1>Something went wrong...</h1><p>The specified Gemini server returned a status of: {i}</p></body></html>'
else: