diff options
-rw-r--r-- | lib/private/Files/Storage/Wrapper/Encoding.php | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/private/Files/Storage/Wrapper/Encoding.php b/lib/private/Files/Storage/Wrapper/Encoding.php index 92e20cfb3df..d6d32aaaf7f 100644 --- a/lib/private/Files/Storage/Wrapper/Encoding.php +++ b/lib/private/Files/Storage/Wrapper/Encoding.php @@ -37,7 +37,7 @@ class Encoding extends Wrapper { * Returns whether the given string is only made of ASCII characters */ private function isAscii(string $str): bool { - return !preg_match('/[\\x80-\\xff]+/', $str); + return mb_check_encoding($str, 'ASCII'); } /** |