Change plugins download directory

[MAILPOET-3482]
This commit is contained in:
Rostislav Wolny
2021-04-16 17:08:16 +02:00
committed by Veljko V
parent 03f25fdf64
commit 44f1269916
4 changed files with 8 additions and 4 deletions

View File

@@ -37,6 +37,9 @@ class GithubClient {
if (!$assetDownloadUrl) {
throw new \Exception("Release zip for $tag not found");
}
if (!is_dir($downloadDir)) {
mkdir($downloadDir, 0777, true);
}
$this->httpClient->get($assetDownloadUrl, ['sink' => $downloadDir . $zip, 'headers' => ['Accept' => 'application/octet-stream']]);
}