From 8127a3d7f17b0740254a5935de97fa03312a4efd Mon Sep 17 00:00:00 2001 From: =?utf8?q?David=20=E2=80=98Bombe=E2=80=99=20Roden?= Date: Fri, 5 Nov 2010 10:29:31 +0100 Subject: [PATCH] Use traditional getter name. --- src/main/java/net/pterodactylus/sone/web/SoneTemplatePage.java | 2 +- src/main/java/net/pterodactylus/sone/web/WebInterface.java | 4 ++-- src/main/java/net/pterodactylus/sone/web/ajax/GetTranslationPage.java | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/main/java/net/pterodactylus/sone/web/SoneTemplatePage.java b/src/main/java/net/pterodactylus/sone/web/SoneTemplatePage.java index 1646935..f38e845 100644 --- a/src/main/java/net/pterodactylus/sone/web/SoneTemplatePage.java +++ b/src/main/java/net/pterodactylus/sone/web/SoneTemplatePage.java @@ -73,7 +73,7 @@ public class SoneTemplatePage extends TemplatePage { * Whether this page requires a login */ public SoneTemplatePage(String path, Template template, String pageTitleKey, WebInterface webInterface, boolean requireLogin) { - super(path, template, webInterface.l10n(), pageTitleKey, "noPermission.html"); + super(path, template, webInterface.getL10n(), pageTitleKey, "noPermission.html"); this.webInterface = webInterface; this.requireLogin = requireLogin; template.set("webInterface", webInterface); diff --git a/src/main/java/net/pterodactylus/sone/web/WebInterface.java b/src/main/java/net/pterodactylus/sone/web/WebInterface.java index 2ba96ec..c6dbca9 100644 --- a/src/main/java/net/pterodactylus/sone/web/WebInterface.java +++ b/src/main/java/net/pterodactylus/sone/web/WebInterface.java @@ -120,7 +120,7 @@ public class WebInterface { * * @return The node’s l10n helper */ - public BaseL10n l10n() { + public BaseL10n getL10n() { return sonePlugin.l10n().getBase(); } @@ -181,7 +181,7 @@ public class WebInterface { templateFactory.addAccessor(Reply.class, new ReplyAccessor(core())); templateFactory.addAccessor(Identity.class, new IdentityAccessor(core())); templateFactory.addFilter("date", new DateFilter()); - templateFactory.addFilter("l10n", new L10nFilter(l10n())); + templateFactory.addFilter("l10n", new L10nFilter(getL10n())); templateFactory.addFilter("substring", new SubstringFilter()); templateFactory.addFilter("xml", new XmlFilter()); templateFactory.addFilter("change", new RequestChangeFilter()); diff --git a/src/main/java/net/pterodactylus/sone/web/ajax/GetTranslationPage.java b/src/main/java/net/pterodactylus/sone/web/ajax/GetTranslationPage.java index 68f1777..20f1636 100644 --- a/src/main/java/net/pterodactylus/sone/web/ajax/GetTranslationPage.java +++ b/src/main/java/net/pterodactylus/sone/web/ajax/GetTranslationPage.java @@ -47,7 +47,7 @@ public class GetTranslationPage extends JsonPage { @Override protected JsonObject createJsonObject(Request request) { String key = request.getHttpRequest().getParam("key"); - String translation = webInterface.l10n().getString(key); + String translation = webInterface.getL10n().getString(key); return new JsonObject().put("value", translation); } -- 2.7.4