Pagekit\Console\Commands\SelfupdateCommand::download PHP Метод

download() публичный Метод

public download ( $url, $file )
$url
$file
    public function download($url, $file)
    {
        if (!$url) {
            throw new \RuntimeException('Package url is missing.');
        }
        if (!file_put_contents($file, @fopen($url, 'r'))) {
            App::abort(500, 'Download failed or Path not writable.');
        }
    }