diff --git a/lib/response.js b/lib/response.js index a163e9d40d..a8256d6f01 100644 --- a/lib/response.js +++ b/lib/response.js @@ -569,7 +569,7 @@ res.redirect = function(url){ var path = app.path(); // relative to path - if (0 == url.indexOf('./') || 0 == url.indexOf('..')) { + if ('.' == url[0]) { url = req.path + '/' + url; // relative to mount-point } else if ('/' != url[0]) {