diff --git a/src/Service/PharHelperService.php b/src/Service/PharHelperService.php index 0a01dc5..783b445 100644 --- a/src/Service/PharHelperService.php +++ b/src/Service/PharHelperService.php @@ -130,7 +130,10 @@ class PharHelperService */ public function copy(string $source, string $target): bool { - return copy($this->getPharUrl($source), $target); + if ($this->isInPhar() && substr($source, 0, 4) !== 'phar') { + $source = $this->getPharUrl($source); + } + return copy($source, $target); }