From f913156a724dd4284169cae9818e7fc8da1fe2e8 Mon Sep 17 00:00:00 2001 From: zds <49744633+zds-s@users.noreply.github.com> Date: Fri, 19 Jul 2024 13:17:58 +0800 Subject: [PATCH] Optimize download logic (#118) * optimal AppStore download * Apply cs fix --- src/Service/Impl/AppStoreServiceImpl.php | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/Service/Impl/AppStoreServiceImpl.php b/src/Service/Impl/AppStoreServiceImpl.php index f36a3d1..c8c5e6e 100644 --- a/src/Service/Impl/AppStoreServiceImpl.php +++ b/src/Service/Impl/AppStoreServiceImpl.php @@ -99,7 +99,10 @@ public function download(string $space, string $identifier, string $version): bo throw new \RuntimeException(sprintf('The plugin %s already exists', $identifier)); } - $originData = $this->request(__FUNCTION__, compact('identifier', 'version')); + $originData = $this->request(__FUNCTION__, [ + 'identifier' => $space . '/' . $identifier, + 'version' => $version, + ]); $downloadResponse = Collection::make($originData); if (! $downloadResponse->get('success')) { throw new \RuntimeException('服务端返回错误' . $downloadResponse->get('message'));