X-Git-Url: https://git.pterodactylus.net/?p=Sone.git;a=blobdiff_plain;f=src%2Fmain%2Fkotlin%2Fnet%2Fpterodactylus%2Fsone%2Fweb%2Fpages%2FNewPage.kt;h=d464db7a123f2d55055878f26cd661c989746f5d;hp=a7bd2face95541cdacd1d2184bd66341599870f0;hb=6a3f1fede0cda5cd6ed56204aa1dd37a19813cb9;hpb=6b0fc27624fc311424452decc28da50a81f4ae2a diff --git a/src/main/kotlin/net/pterodactylus/sone/web/pages/NewPage.kt b/src/main/kotlin/net/pterodactylus/sone/web/pages/NewPage.kt index a7bd2fa..d464db7 100644 --- a/src/main/kotlin/net/pterodactylus/sone/web/pages/NewPage.kt +++ b/src/main/kotlin/net/pterodactylus/sone/web/pages/NewPage.kt @@ -1,5 +1,6 @@ package net.pterodactylus.sone.web.pages +import net.pterodactylus.sone.main.* import net.pterodactylus.sone.utils.mapPresent import net.pterodactylus.sone.utils.paginate import net.pterodactylus.sone.utils.parameters @@ -14,8 +15,8 @@ import javax.inject.Inject * [PostVisibilityFilter.isPostVisible(Sone, Post)] and sorted by time. */ @MenuName("New") -class NewPage @Inject constructor( template: Template, webInterface: WebInterface): - SoneTemplatePage("new.html", webInterface, template, "Page.New.Title") { +class NewPage @Inject constructor( template: Template, webInterface: WebInterface, loaders: Loaders): + SoneTemplatePage("new.html", webInterface, loaders, template = template, pageTitleKey = "Page.New.Title") { override fun handleRequest(soneRequest: SoneRequest, templateContext: TemplateContext) = getCurrentSone(soneRequest.toadletContext).let { currentSone ->