Skip to content

Commit

Permalink
Merge pull request #22520 from nextcloud/normalize-path-invalid-utf8
Browse files Browse the repository at this point in the history
dont use `false` as cache key for non utf8 path in normalizePath
  • Loading branch information
rullzer committed Sep 9, 2020
2 parents e7f0348 + a792a51 commit 6895d97
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/private/Files/Filesystem.php
Original file line number Diff line number Diff line change
Expand Up @@ -814,7 +814,7 @@ public static function normalizePath($path, $stripTrailingSlash = true, $isAbsol

$cacheKey = json_encode([$path, $stripTrailingSlash, $isAbsolutePath, $keepUnicode]);

if (isset(self::$normalizedPathCache[$cacheKey])) {
if ($cacheKey && isset(self::$normalizedPathCache[$cacheKey])) {
return self::$normalizedPathCache[$cacheKey];
}

Expand Down

0 comments on commit 6895d97

Please sign in to comment.