Skip to content
Snippets Groups Projects
Commit ca88347d authored by Quentin Ribac's avatar Quentin Ribac
Browse files

FIX #18034 TIME 0:05 using stream_get_contents()

parent d3144bea
No related branches found
No related tags found
No related merge requests found
......@@ -227,7 +227,7 @@ class CoreController
$mimeType = mime_content_type($resource);
$encoding = null;
if (substr($mimeType, 0, 5) === 'text/') {
$encoding = mb_detect_encoding(file_get_contents($resource), ['UTF-8', 'ISO-8859-1', 'ASCII']);
$encoding = mb_detect_encoding(stream_get_contents($resource));
}
rewind($resource);
fclose($resource);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment