import net.pterodactylus.sone.utils.isPOST
import net.pterodactylus.sone.web.WebInterface
import net.pterodactylus.sone.web.page.FreenetRequest
import net.pterodactylus.sone.utils.isPOST
import net.pterodactylus.sone.web.WebInterface
import net.pterodactylus.sone.web.page.FreenetRequest
* Lets the user delete a post they made.
*/
class DeletePostPage(template: Template, webInterface: WebInterface):
* Lets the user delete a post they made.
*/
class DeletePostPage(template: Template, webInterface: WebInterface):
- SoneTemplatePage("deletePost.html", template, "Page.DeletePost.Title", webInterface, true) {
+ LoggedInPage("deletePost.html", template, "Page.DeletePost.Title", webInterface) {
val returnPage = freenetRequest.httpRequest.getPartAsStringFailsafe("returnPage", 256)
if (!post.sone.isLocal) {
throw RedirectException("noPermission.html")
val returnPage = freenetRequest.httpRequest.getPartAsStringFailsafe("returnPage", 256)
if (!post.sone.isLocal) {
throw RedirectException("noPermission.html")