X-Git-Url: https://git.pterodactylus.net/?p=Sone.git;a=blobdiff_plain;f=src%2Fmain%2Fjava%2Fnet%2Fpterodactylus%2Fsone%2Fweb%2FSoneTemplatePage.java;h=bf9614dda9590f1452bdf11d94c3586312c3a139;hp=b3e7a6af680253b8bfd310c95e6a63c6fffdf4fd;hb=7b55e0be6a3283e43a9bbab98f82aebdd948eb33;hpb=c4ae226ec5052116cefc542ae2017036a7bc6332 diff --git a/src/main/java/net/pterodactylus/sone/web/SoneTemplatePage.java b/src/main/java/net/pterodactylus/sone/web/SoneTemplatePage.java index b3e7a6a..bf9614d 100644 --- a/src/main/java/net/pterodactylus/sone/web/SoneTemplatePage.java +++ b/src/main/java/net/pterodactylus/sone/web/SoneTemplatePage.java @@ -236,14 +236,14 @@ public class SoneTemplatePage extends FreenetTemplatePage { * {@inheritDoc} */ @Override - protected void processTemplate(FreenetRequest request, TemplateContext templateContext) throws RedirectException { + protected final void processTemplate(FreenetRequest request, TemplateContext templateContext) throws RedirectException { super.processTemplate(request, templateContext); Sone currentSone = getCurrentSone(request.getToadletContext(), false); templateContext.set("core", webInterface.getCore()); templateContext.set("currentSone", currentSone); templateContext.set("localSones", webInterface.getCore().getLocalSones()); templateContext.set("request", request); - templateContext.set("currentVersion", SonePlugin.VERSION); + templateContext.set("currentVersion", SonePlugin.getPluginVersion()); templateContext.set("hasLatestVersion", webInterface.getCore().getUpdateChecker().hasLatestVersion()); templateContext.set("latestEdition", webInterface.getCore().getUpdateChecker().getLatestEdition()); templateContext.set("latestVersion", webInterface.getCore().getUpdateChecker().getLatestVersion()); @@ -252,6 +252,10 @@ public class SoneTemplatePage extends FreenetTemplatePage { Collections.sort(notifications, Notification.CREATED_TIME_SORTER); templateContext.set("notifications", notifications); templateContext.set("notificationHash", notifications.hashCode()); + handleRequest(request, templateContext); + } + + protected void handleRequest(FreenetRequest request, TemplateContext templateContext) throws RedirectException { } /**