diff --git a/src/DocumentRoot.php b/src/DocumentRoot.php index 6da9efa..2e9551c 100644 --- a/src/DocumentRoot.php +++ b/src/DocumentRoot.php @@ -78,7 +78,11 @@ public function __construct(string $root, File\Driver $filesystem = null) { ); } - $this->root = \rtrim(\realpath($root), "/"); + if (\strncmp($root, "phar://", 7) !== 0) { + $root = \realpath($root); + } + + $this->root = \rtrim($root, "/"); $this->filesystem = $filesystem ?: File\filesystem(); $this->multipartBoundary = \uniqid("", true); }