X-Git-Url: https://git.pterodactylus.net/?p=Sone.git;a=blobdiff_plain;f=src%2Fmain%2Fkotlin%2Fnet%2Fpterodactylus%2Fsone%2Fweb%2Fajax%2FGetTranslationAjaxPage.kt;h=99429e47100ac70fdd0698f78eec0933f6a4ee29;hp=f12a778fb87eb739c3aaf513c564a3309c46053e;hb=ae78f11f111ddc964a36cc25ab6da413685d69a6;hpb=4bf90851f9e7a8f31d4f58f4f74dc46d8e4ddec8 diff --git a/src/main/kotlin/net/pterodactylus/sone/web/ajax/GetTranslationAjaxPage.kt b/src/main/kotlin/net/pterodactylus/sone/web/ajax/GetTranslationAjaxPage.kt index f12a778..99429e4 100644 --- a/src/main/kotlin/net/pterodactylus/sone/web/ajax/GetTranslationAjaxPage.kt +++ b/src/main/kotlin/net/pterodactylus/sone/web/ajax/GetTranslationAjaxPage.kt @@ -3,14 +3,16 @@ package net.pterodactylus.sone.web.ajax import net.pterodactylus.sone.utils.parameters import net.pterodactylus.sone.web.WebInterface import net.pterodactylus.sone.web.page.FreenetRequest +import javax.inject.Inject /** * Returns the translation for a given key as JSON object. */ -class GetTranslationAjaxPage(webInterface: WebInterface) : JsonPage("getTranslation.ajax", webInterface) { +class GetTranslationAjaxPage @Inject constructor(webInterface: WebInterface) : + JsonPage("getTranslation.ajax", webInterface) { override val needsFormPassword = false - override fun requiresLogin() = false + override val requiresLogin = false override fun createJsonObject(request: FreenetRequest) = createSuccessJsonObject()