From 519adb506073f4c3e2afd57e6ba1b6da4569e606 Mon Sep 17 00:00:00 2001 From: Marc Alexander Date: Thu, 3 Apr 2014 15:55:18 +0200 Subject: [PATCH] [ticket/10851] Set disallowed content to empty array if checking is disabled The disallowed content defaults to a standard set of mimetype triggers by default. If one doesn't want to check the attachments mimetype triggers then we need to set the disallowed content to an empty array. PHPBB3-10851 --- phpBB/includes/functions_posting.php | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/phpBB/includes/functions_posting.php b/phpBB/includes/functions_posting.php index 11a5067ef9..3f0a78a7cb 100644 --- a/phpBB/includes/functions_posting.php +++ b/phpBB/includes/functions_posting.php @@ -394,6 +394,10 @@ function upload_attachment($form_name, $forum_id, $local = false, $local_storage { $upload->set_disallowed_content(explode('|', $config['mime_triggers'])); } + else if (!$config['check_attachment_content']) + { + $upload->set_disallowed_content(array()); + } if (!$local) {