From 5d9090cd52b7fe3bc8e66a9ce19ffc795f8d3c60 Mon Sep 17 00:00:00 2001 From: Shish Date: Mon, 5 Feb 2024 13:27:40 +0000 Subject: [PATCH] [comment] handle people posting junk --- ext/comment/theme.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/comment/theme.php b/ext/comment/theme.php index bfd0dfe0..b5bf49cf 100644 --- a/ext/comment/theme.php +++ b/ext/comment/theme.php @@ -255,7 +255,7 @@ class CommentListTheme extends Themelet $h_del = ""; if ($user->can(Permissions::DELETE_COMMENT)) { $comment_preview = substr(html_unescape($tfe->stripped), 0, 50); - $j_delete_confirm_message = json_encode_ex("Delete comment by {$comment->owner_name}:\n$comment_preview"); + $j_delete_confirm_message = json_encode("Delete comment by {$comment->owner_name}:\n$comment_preview") ?: "Delete "; $h_delete_script = html_escape("return confirm($j_delete_confirm_message);"); $h_delete_link = make_link("comment/delete/$i_comment_id/$i_image_id"); $h_del = " - Del";