From: Vincent Vanwaelscappel Date: Fri, 31 Mar 2023 11:53:22 +0000 (+0200) Subject: wip #5611 X-Git-Url: http://git.cubedesigners.com/?a=commitdiff_plain;h=4dad0f1bddd1e5c0655db0d7a975a1de52c23f22;p=cubist_net.git wip #5611 --- diff --git a/src/Transfer/Driver.php b/src/Transfer/Driver.php index 53c1d30..7381e8e 100644 --- a/src/Transfer/Driver.php +++ b/src/Transfer/Driver.php @@ -31,7 +31,7 @@ abstract class Driver { $this->_server = $server; } - protected static function _cleanInstallDir($path) { + public static function cleanInstallDir($path) { $path = str_replace('/\.{2,}/', '', $path); $path = preg_replace('/\/{2,}/', '/', $path); $path = trim($path, '/'); @@ -39,7 +39,7 @@ abstract class Driver { } protected function _destPath($path) { - return self::_cleanInstallDir($path); + return self::cleanInstallDir($path); } /** diff --git a/src/Transfer/Local.php b/src/Transfer/Local.php index 56092e3..b0b1a30 100644 --- a/src/Transfer/Local.php +++ b/src/Transfer/Local.php @@ -33,7 +33,7 @@ class Local extends Driver { * @return string */ protected function _destPath($path) { - return rtrim($this->getRootPath(), '/') . '/' . self::_cleanInstallDir($path) . '/'; + return rtrim($this->getRootPath(), '/') . '/' . self::cleanInstallDir($path) . '/'; } public function copy($source, $dest, $mirror = false, $dryrun = false) {