Skip to content

Commit b30ff7a

Browse files
committed
Use full path on working direcor and fix the detection of external path
1 parent d021063 commit b30ff7a

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

src/FireFS/FireFS.php

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -252,7 +252,7 @@ public function explodePath(string $path): array
252252
*/
253253
public function setWorkingDir(string $workingDir)
254254
{
255-
$this->workingDir = $workingDir;
255+
$this->workingDir = $this->toExternalPath($workingDir);
256256
}
257257

258258
/**
@@ -856,6 +856,10 @@ public function toExternalPath(string $internalPath): string
856856
}
857857
}
858858

859+
if (strlen($externalPath) === 0) {
860+
return $this->cleanPath("./");
861+
}
862+
859863
if ($externalPath[0] != '/') {
860864
return $internalPath;
861865
}

0 commit comments

Comments
 (0)