Set variables correctly on new-version notification
authorDavid ‘Bombe’ Roden <bombe@pterodactylus.net>
Sat, 27 Feb 2016 08:48:32 +0000 (09:48 +0100)
committerDavid ‘Bombe’ Roden <bombe@pterodactylus.net>
Sat, 27 Feb 2016 09:54:08 +0000 (10:54 +0100)
src/main/java/net/pterodactylus/sone/web/WebInterface.java

index 934b4b5..4b4ac88 100644 (file)
@@ -1019,10 +1019,10 @@ public class WebInterface {
         */
        @Subscribe
        public void updateFound(UpdateFoundEvent updateFoundEvent) {
-               newVersionNotification.getTemplateContext().set("latestVersion", updateFoundEvent.version());
-               newVersionNotification.getTemplateContext().set("latestEdition", updateFoundEvent.latestEdition());
-               newVersionNotification.getTemplateContext().set("releaseTime", updateFoundEvent.releaseTime());
-               newVersionNotification.getTemplateContext().set("disruptive", updateFoundEvent.disruptive());
+               newVersionNotification.set("latestVersion", updateFoundEvent.version());
+               newVersionNotification.set("latestEdition", updateFoundEvent.latestEdition());
+               newVersionNotification.set("releaseTime", updateFoundEvent.releaseTime());
+               newVersionNotification.set("disruptive", updateFoundEvent.disruptive());
                notificationManager.addNotification(newVersionNotification);
        }