fix: 修复HTTP传递参数错误

This commit is contained in:
Ying
2023-07-18 10:13:39 +08:00
parent f5bac77f45
commit 918a5253b2

View File

@@ -354,7 +354,7 @@ class Plugin extends AdminController
$url = $body['data']['url']; $url = $body['data']['url'];
} }
if (!empty($url) && stristr($url, 'download')) { if (!empty($url) && stristr($url, 'download')) {
$content = Http::get($url); $content = file_get_contents($url);
$filePath = plugin_path() . $name . '.zip'; $filePath = plugin_path() . $name . '.zip';
write_file($filePath, $content); write_file($filePath, $content);
} else { } else {