From ac8f15f0f24a0a5e291089d5d7885edd39278e4b Mon Sep 17 00:00:00 2001 From: Fredrick Brennan Date: Sun, 5 Nov 2017 16:25:02 +0800 Subject: [PATCH] Close #267 --- post.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/post.php b/post.php index 3f37f0f8..b30993e9 100644 --- a/post.php +++ b/post.php @@ -655,7 +655,7 @@ if (isset($_POST['delete'])) { if ($post['has_file']) { $i = 0; foreach ($_FILES as $key => $file) { - if ($file['error'] > 0) { + if (!in_array($file['error'], array(UPLOAD_ERR_NO_FILE, UPLOAD_ERR_OK))) { error(sprintf3($config['error']['phpfileserror'], array( 'index' => $i+1, 'code' => $file['error']