Better handling for directory default index response (for instance index.html) for case like "/subdir" which is now redirected to "/subdir/" so relative url are correctly handled.
This commit is contained in:
@@ -221,8 +221,10 @@ feature -- Execution
|
|||||||
if f.is_directory then
|
if f.is_directory then
|
||||||
if index_disabled then
|
if index_disabled then
|
||||||
process_directory_index_disabled (uri, req, res)
|
process_directory_index_disabled (uri, req, res)
|
||||||
|
elseif uri.ends_with ("/") then
|
||||||
|
process_index (uri, fn, req, res)
|
||||||
else
|
else
|
||||||
process_index (req.request_uri, fn, req, res)
|
res.redirect_now (uri + "/")
|
||||||
end
|
end
|
||||||
else
|
else
|
||||||
process_file (f, req, res)
|
process_file (f, req, res)
|
||||||
@@ -652,7 +654,7 @@ feature {NONE} -- implementation: date time
|
|||||||
end
|
end
|
||||||
|
|
||||||
note
|
note
|
||||||
copyright: "2011-2017, Jocelyn Fiat, Javier Velilla, Olivier Ligot, Colin Adams, Eiffel Software and others"
|
copyright: "2011-2019, Jocelyn Fiat, Javier Velilla, Olivier Ligot, Colin Adams, Eiffel Software and others"
|
||||||
license: "Eiffel Forum License v2 (see http://www.eiffel.com/licensing/forum.txt)"
|
license: "Eiffel Forum License v2 (see http://www.eiffel.com/licensing/forum.txt)"
|
||||||
source: "[
|
source: "[
|
||||||
Eiffel Software
|
Eiffel Software
|
||||||
|
|||||||
Reference in New Issue
Block a user