diff options
author | Ugnich Anton | 2012-01-27 08:31:23 +0700 |
---|---|---|
committer | Ugnich Anton | 2012-01-27 08:31:23 +0700 |
commit | a0e43fc8a853a71b6aa85f93843c1692a4d13708 (patch) | |
tree | 9790fb04141a30073038262ceb3546fdf4d1b678 /src/java/com/juick/http/www/Login.java | |
parent | 6f4e181f0a03b4b190922bd5f8bd97fb9fdb206e (diff) |
SAPE, NewMessage (GET)
Diffstat (limited to 'src/java/com/juick/http/www/Login.java')
-rw-r--r-- | src/java/com/juick/http/www/Login.java | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/src/java/com/juick/http/www/Login.java b/src/java/com/juick/http/www/Login.java index d03dd64d..1baf6e43 100644 --- a/src/java/com/juick/http/www/Login.java +++ b/src/java/com/juick/http/www/Login.java @@ -57,7 +57,7 @@ public class Login { out.println("</div>"); out.println("</div>"); - PageTemplates.pageFooter(out, locale); + PageTemplates.pageFooter(request, out, locale, visitor); } finally { out.close(); } @@ -98,7 +98,12 @@ public class Login { c.setMaxAge(0); response.addCookie(c); - response.sendRedirect("/"); + String referer = request.getHeader("Referer"); + if (referer != null && referer.startsWith("http://juick.com/") && !referer.equals("http://juick.com/login")) { + response.sendRedirect(referer); + } else { + response.sendRedirect("/"); + } } else { response.sendError(403); } |