fhttpy/modules/http/404.py
2022-02-14 22:43:12 +01:00

8 lines
230 B
Python

global handle404
def handle404(env):
newPath = "/" + pathToURL(env["pathFixed"])
rawArgs = env["protocolHeaderList"][1].split("?",1)
if len(rawArgs) > 1:
newPath += "?" +rawArgs[-1]
notFound(env["self"].connection,newPath)