Update server.py
This commit is contained in:
parent
738ddadfac
commit
d99da841fc
1 changed files with 2 additions and 2 deletions
|
@ -100,11 +100,11 @@ def relay():
|
||||||
tempurl = "/".join(url.split("/")[:-1]) + "/" + goto
|
tempurl = "/".join(url.split("/")[:-1]) + "/" + goto
|
||||||
goto = f"/gem?gemini={tempurl}"
|
goto = f"/gem?gemini={tempurl}"
|
||||||
elif prse.scheme != "gemini":
|
elif prse.scheme != "gemini":
|
||||||
extra = "<img height=\"12\" src=\"/external.png\">"
|
extra = "<img height=\"19\" src=\"/external.png\">"
|
||||||
extracomment = f"This link points to an address that isn't gemini ({prse.scheme})"
|
extracomment = f"This link points to an address that isn't gemini ({prse.scheme})"
|
||||||
else:
|
else:
|
||||||
if prse.hostname != urlparse(fulladdr).hostname:
|
if prse.hostname != urlparse(fulladdr).hostname:
|
||||||
extra = "<img height=\"12\" src=\"/cross-server.png\">"
|
extra = "<img height=\"19\" src=\"/cross-server.png\">"
|
||||||
extracomment = f"This link points to an address that isn't from the server you're currently connecting to ({prse.hostname})"
|
extracomment = f"This link points to an address that isn't from the server you're currently connecting to ({prse.hostname})"
|
||||||
goto = goto.replace("gemini://", "")
|
goto = goto.replace("gemini://", "")
|
||||||
goto = f"/gem?gemini={goto}"
|
goto = f"/gem?gemini={goto}"
|
||||||
|
|
Loading…
Add table
Reference in a new issue