From 2088ee5e84ba2aeb2c9e598c102013b09c5754ef Mon Sep 17 00:00:00 2001 From: Marc Alexander Date: Mon, 8 Jul 2024 21:37:05 +0200 Subject: [PATCH] [ticket/15576] Handle subject max length same as in form input PHPBB-15576 --- phpBB/includes/functions_privmsgs.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/phpBB/includes/functions_privmsgs.php b/phpBB/includes/functions_privmsgs.php index 0aceeb90e1..4e3fd5a85e 100644 --- a/phpBB/includes/functions_privmsgs.php +++ b/phpBB/includes/functions_privmsgs.php @@ -1689,7 +1689,7 @@ function submit_pm($mode, $subject, &$data_ary, $put_in_outbox = true) } // First of all make sure the subject are having the correct length. - $subject = truncate_string($subject); + $subject = truncate_string($subject, $mode === 'post' ? 120 : 124); $db->sql_transaction('begin');