diff --git a/rhodecode/lib/auth.py b/rhodecode/lib/auth.py --- a/rhodecode/lib/auth.py +++ b/rhodecode/lib/auth.py @@ -330,14 +330,7 @@ class LoginRequired(object): return func(*fargs, **fkwargs) else: log.warn('user %s NOT authenticated', user.username) - - p = '' - if request.environ.get('SCRIPT_NAME') != '/': - p += request.environ.get('SCRIPT_NAME') - - p += request.environ.get('PATH_INFO') - if request.environ.get('QUERY_STRING'): - p += '?' + request.environ.get('QUERY_STRING') + p = url.current() log.debug('redirecting to login page with %s', p) return redirect(url('login_home', came_from=p))