Commit 2b8b7681 authored by Quentin Ribac's avatar Quentin Ribac
Browse files

FIX #17437 TIME 0 better error messages

parent ed789881
......@@ -161,9 +161,6 @@ class CoreController
$resource = null;
$size = null;
if (!empty($args['encodedFile'])) {
if (!is_string($args['encodedFile'])) {
return ['errors' => 'args encodedFile is not a string'];
}
$resource = fopen('php://temp', 'r+');
$streamFilterBase64 = stream_filter_append($resource, 'convert.base64-decode', STREAM_FILTER_WRITE);
stream_set_chunk_size($resource, 1024*1024);
......@@ -178,7 +175,7 @@ class CoreController
}
if (empty($resource)) {
return ['errors' => 'missing parameter: getMimeType requires encodedFile, resource, or filename'];
return ['errors' => 'could not decode encoded data, or open target file'];
}
rewind($resource);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment