X-Git-Url: https://git.pterodactylus.net/?a=blobdiff_plain;f=src%2Fmain%2Fjava%2Fnet%2Fpterodactylus%2Fsone%2Fweb%2FLogoutPage.java;h=3ec62a37ce9575501eadb67e340ab428e48a334d;hb=fe8a83bdb1d644d4d1bf4342feab4c58115409b3;hp=d47044c8f98d5e19380d0b17a6a0b9010b613a07;hpb=c4ae226ec5052116cefc542ae2017036a7bc6332;p=Sone.git diff --git a/src/main/java/net/pterodactylus/sone/web/LogoutPage.java b/src/main/java/net/pterodactylus/sone/web/LogoutPage.java index d47044c..3ec62a3 100644 --- a/src/main/java/net/pterodactylus/sone/web/LogoutPage.java +++ b/src/main/java/net/pterodactylus/sone/web/LogoutPage.java @@ -47,9 +47,8 @@ public class LogoutPage extends SoneTemplatePage { * {@inheritDoc} */ @Override - protected void processTemplate(FreenetRequest request, TemplateContext templateContext) throws RedirectException { + protected void handleRequest(FreenetRequest request, TemplateContext templateContext) throws RedirectException { setCurrentSone(request.getToadletContext(), null); - super.processTemplate(request, templateContext); throw new RedirectException("index.html"); } @@ -61,7 +60,7 @@ public class LogoutPage extends SoneTemplatePage { if (webInterface.getCore().getPreferences().isRequireFullAccess() && !toadletContext.isAllowedFullAccess()) { return false; } - return (getCurrentSone(toadletContext, false) != null) && (webInterface.getCore().getLocalSones().size() != 1); + return (getCurrentSoneWithoutCreatingSession(toadletContext) != null) && (webInterface.getCore().getLocalSones().size() != 1); } }