diff options
Diffstat (limited to 'tekuti/page.scm')
-rw-r--r-- | tekuti/page.scm | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/tekuti/page.scm b/tekuti/page.scm index b2fa305..6844a95 100644 --- a/tekuti/page.scm +++ b/tekuti/page.scm @@ -42,6 +42,7 @@ page-admin-new-post page-admin-modify-post page-admin-delete-post + page-admin-delete-comment page-admin-changes page-admin-change page-admin-revert-change @@ -133,6 +134,14 @@ (delete-post key) (respond `((p "redirecting...")) #:redirect (relurl `("admin")))))) +(define (page-admin-delete-comment request body index key comment-id) + (with-authentication + request + (lambda () + (let ((post (post-from-key (assq-ref index 'master) key #t))) + (delete-comment post comment-id) + (respond `((p "redirecting...")) #:redirect (admin-post-url post)))))) + (define (page-admin-changes request body index) (with-authentication request |