Do login_required redirect by path
Reported by Betelgeuse | April 12th, 2010 @ 01:47 PM
~ $ curl -i http://localhost:3000/
HTTP/1.1 302 Moved Temporarily
Connection: close
Date: Mon, 12 Apr 2010 12:36:55 GMT
Location: http://localhost:3000/login
Content-Type: text/html; charset=utf-8
X-Runtime: 4
Content-Length: 93
Set-Cookie: _mailer_session=BAh7BzoOcmV0dXJuX3RvIgYvOg9zZXNzaW9uX2lkIiVmYmNiZTAyMWUwMWJjYTBmN2ZhNmRmZjUyNjY5ZDViNg%3D%3D--b60d01711a4811a72be6a7dadc4975687f916211; path=/; HttpOnly
Cache-Control: no-cache
<html><body>You are being <a href="http://localhost:3000/login">redirected</a>.</body></html>
The login_required before filter uses login_url. I think login_path is a better default here.
Comments and changes to this ticket
-
Betelgeuse April 12th, 2010 @ 02:08 PM
Guess I should have done some more research. It seems the HTTP 1.1 specification requires stuff to be absolute.
-
Bryan Larsen April 12th, 2010 @ 08:57 PM
- State changed from new to invalid
I tried changing it, hoping that it would leave the header absolute and use a relative path in the HTML, but no go.
Please Sign in or create a free account to add a new ticket.
With your very own profile, you can contribute to projects, track your activity, watch tickets, receive and update tickets through your email and much more.
Create your profile
Help contribute to this project by taking a few moments to create your personal profile. Create your profile ยป