From 68887105b288ccfb1e999a124b3728507f6b7dc1 Mon Sep 17 00:00:00 2001 From: "Dylan K. Taylor" Date: Wed, 9 Dec 2020 20:26:08 +0000 Subject: [PATCH] Utils::cleanPath(): drop the square braces this looks ugly, as well as breaking plugin crash detection (which tbh is too fragile, but it is what it is ...) --- src/pocketmine/utils/Utils.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/pocketmine/utils/Utils.php b/src/pocketmine/utils/Utils.php index 77ef53f16..ff9813a8f 100644 --- a/src/pocketmine/utils/Utils.php +++ b/src/pocketmine/utils/Utils.php @@ -613,7 +613,7 @@ class Utils{ foreach($cleanPaths as $cleanPath => $replacement){ $cleanPath = rtrim(str_replace([DIRECTORY_SEPARATOR, "phar://"], ["/", ""], $cleanPath), "/"); if(strpos($result, $cleanPath) === 0){ - $result = ltrim(str_replace($cleanPath, "[$replacement]", $result), "/"); + $result = ltrim(str_replace($cleanPath, $replacement, $result), "/"); } } return $result;