From 29150ebc65d0d4cf90da3f437999395a86609504 Mon Sep 17 00:00:00 2001 From: Ugnich Anton Date: Wed, 10 Apr 2013 05:00:41 +0700 Subject: VKontakte login --- src/java/com/juick/http/www/Login.java | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) (limited to 'src/java/com/juick/http/www/Login.java') diff --git a/src/java/com/juick/http/www/Login.java b/src/java/com/juick/http/www/Login.java index 3a715870..7ad921e0 100644 --- a/src/java/com/juick/http/www/Login.java +++ b/src/java/com/juick/http/www/Login.java @@ -37,6 +37,11 @@ public class Login { protected void doGetLoginForm(Connection sql, HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException { com.juick.User visitor = Utils.getVisitorUser(sql, request); + if (visitor != null) { + Utils.sendTemporaryRedirect(response, "/"); + return; + } + Locale locale = request.getLocale(); ResourceBundle rb = ResourceBundle.getBundle("Login", locale); @@ -52,6 +57,9 @@ public class Login { out.println("
" + rb.getString("Login VK text") + "
"); + out.println("" + rb.getString("XMPP instructions") + "
"); out.println("