Strip leading slashes from referers

This commit is contained in:
Omar Roth 2018-09-05 21:07:19 -05:00
parent 96234e509f
commit 29a21860ae

View File

@ -184,6 +184,7 @@ def get_referer(env, fallback = "/")
end
referer = referer.full_path
referer = "/" + referer.lstrip("\/\\")
if referer == env.request.path
referer = fallback