aboutsummaryrefslogtreecommitdiff
path: root/juick-www/src/main/java/com/juick/www/WebApp.java
diff options
context:
space:
mode:
authorGravatar Vitaly Takmazov2017-03-29 14:11:46 +0300
committerGravatar Vitaly Takmazov2017-03-29 14:11:46 +0300
commit9f770c26d1e4f392d591bf35886e3dcc7371d64f (patch)
tree5fccb22b5c01b40d81a111de61e5fbf27f55a18f /juick-www/src/main/java/com/juick/www/WebApp.java
parent889a5e543d33e3305bccd77e52722da695e068f7 (diff)
juick-www: Spring Security
Diffstat (limited to 'juick-www/src/main/java/com/juick/www/WebApp.java')
-rw-r--r--juick-www/src/main/java/com/juick/www/WebApp.java17
1 files changed, 0 insertions, 17 deletions
diff --git a/juick-www/src/main/java/com/juick/www/WebApp.java b/juick-www/src/main/java/com/juick/www/WebApp.java
index 2d95cb85..72eb3fbc 100644
--- a/juick-www/src/main/java/com/juick/www/WebApp.java
+++ b/juick-www/src/main/java/com/juick/www/WebApp.java
@@ -19,7 +19,6 @@ package com.juick.www;
import com.juick.Message;
import com.juick.Tag;
-import com.juick.User;
import com.juick.service.TagService;
import com.juick.service.UserService;
import com.juick.www.controllers.PageTemplates;
@@ -36,8 +35,6 @@ import rocks.xmpp.core.session.XmppSessionConfiguration;
import rocks.xmpp.core.session.debug.LogbackDebugger;
import rocks.xmpp.extensions.component.accept.ExternalComponent;
-import javax.servlet.http.HttpServletRequest;
-import javax.servlet.http.HttpServletResponse;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.List;
@@ -103,20 +100,6 @@ public class WebApp implements AutoCloseable {
return xmpp;
}
-
- public com.juick.User getVisitorUser(HttpServletRequest request, HttpServletResponse response) {
- String hash = Utils.getCookie(request, "hash");
- if (hash != null) {
- com.juick.User visitor = userService.getUserByHash(hash);
- if (response != null && visitor.getUid() > 0) {
- response.setHeader("X-Username", visitor.getName());
- }
- return visitor;
- } else {
- return new User();
- }
- }
-
public String getImgDir() {
return imgDir;
}