mirror of
https://github.com/django/django.git
synced 2025-10-24 14:16:09 +00:00
Fixed #23173 -- Fixed incorrect stripping of SCRIPT_URL
This commit is contained in:
committed by
Markus Holtermann
parent
a5b225084f
commit
336512fae7
@@ -219,7 +219,7 @@ def get_script_name(environ):
|
||||
|
||||
if script_url:
|
||||
path_info = get_bytes_from_wsgi(environ, 'PATH_INFO', '')
|
||||
script_name = script_url[:-len(path_info)]
|
||||
script_name = script_url[:-len(path_info)] if path_info else script_url
|
||||
else:
|
||||
script_name = get_bytes_from_wsgi(environ, 'SCRIPT_NAME', '')
|
||||
|
||||
|
||||
Reference in New Issue
Block a user