Skip to content
Snippets Groups Projects
Commit 9d7543ce authored by ale's avatar ale
Browse files

Fix filesize() call on non-existing file

parent 685b8bce
Branches
Tags v0.0.11
No related merge requests found
Pipeline #54109 passed
...@@ -3,7 +3,7 @@ ...@@ -3,7 +3,7 @@
* Plugin Name: wp-mat * Plugin Name: wp-mat
* Plugin URI: https://git.autistici.org/noblogs/wp-mat * Plugin URI: https://git.autistici.org/noblogs/wp-mat
* Description: Process uploaded files through MAT * Description: Process uploaded files through MAT
* Version: 0.0.10 * Version: 0.0.11
* Author: Autistici/Inventati * Author: Autistici/Inventati
* Author URI: https://www.autistici.org/ * Author URI: https://www.autistici.org/
* License: MIT * License: MIT
...@@ -82,7 +82,7 @@ function wp_mat_handle_upload_prefilter($file) { ...@@ -82,7 +82,7 @@ function wp_mat_handle_upload_prefilter($file) {
"name" => $file['name'], "name" => $file['name'],
"type" => $file['type'], "type" => $file['type'],
"tmp_name" => $file['tmp_name'], "tmp_name" => $file['tmp_name'],
"size" => filesize($new_tmp_file), "size" => filesize($file['tmp_name']),
"error" => 0, "error" => 0,
); );
error_log("wp-mat: successfully cleaned file=".json_encode($new_file)); error_log("wp-mat: successfully cleaned file=".json_encode($new_file));
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment