Skip to content

Commit 2927e38

Browse files
committed
fix(Preview): reorder encodings for detection
Signed-off-by: Ferdinand Thiessen <opensource@fthiessen.de>
1 parent 9da2963 commit 2927e38

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

lib/private/Preview/SVG.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -98,7 +98,7 @@ public function getThumbnail(File $file, int $maxX, int $maxY): ?IImage {
9898
*/
9999
protected function canBeProcessed(string $content): bool {
100100
// check for allowed encodings and convert if necessary
101-
$encoding = mb_detect_encoding($content, ['UTF-8', 'ISO-2022-JP', 'ISO-8859-1'], true);
101+
$encoding = mb_detect_encoding($content, ['ISO-2022-JP', 'UTF-8', 'ISO-8859-1'], true);
102102
if ($encoding === false) {
103103
return false;
104104
} elseif ($encoding !== 'UTF-8') {

0 commit comments

Comments
 (0)