From 12ea3218e89409b368fc8a9b2aa86230727408d6 Mon Sep 17 00:00:00 2001 From: crazywhalecc Date: Mon, 8 Jan 2024 23:32:04 +0800 Subject: [PATCH] fix --from-zip not working bug --- src/SPC/command/DownloadCommand.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/SPC/command/DownloadCommand.php b/src/SPC/command/DownloadCommand.php index 15d55e88..5bb6e79d 100644 --- a/src/SPC/command/DownloadCommand.php +++ b/src/SPC/command/DownloadCommand.php @@ -188,7 +188,8 @@ class DownloadCommand extends BaseCommand // create downloads try { if (PHP_OS_FAMILY !== 'Windows') { - f_passthru('mkdir ' . DOWNLOAD_PATH . ' && cd ' . DOWNLOAD_PATH . ' && unzip ' . escapeshellarg($path)); + $abs_path = realpath($path); + f_passthru('mkdir ' . DOWNLOAD_PATH . ' && cd ' . DOWNLOAD_PATH . ' && unzip ' . escapeshellarg($abs_path)); } // Windows TODO