mirror of
				https://github.com/crater-invoice/crater.git
				synced 2025-10-31 05:31:10 -04:00 
			
		
		
		
	refactor updater
This commit is contained in:
		| @ -4,20 +4,21 @@ namespace Laraspace\Space; | ||||
|  | ||||
| use GuzzleHttp\Client; | ||||
| use GuzzleHttp\Exception\RequestException; | ||||
| use Laraspace\Setting; | ||||
|  | ||||
| trait SiteApi | ||||
| { | ||||
|  | ||||
|     protected static function getRemote($url, $data = array()) | ||||
|     { | ||||
|         $base = 'https://codeload.github.com/'; | ||||
|         $base = 'http://download-test.test/'; | ||||
|  | ||||
|         $client = new Client(['verify' => false, 'base_uri' => $base]); | ||||
|  | ||||
|         $headers['headers'] = array( | ||||
|             'Accept'        => 'application/json', | ||||
|             'Referer'       => url('/'), | ||||
|             'crater'        => getFullVersion() | ||||
|             'crater'        => Setting::getSetting('version') | ||||
|         ); | ||||
|  | ||||
|         $data['http_errors'] = false; | ||||
|  | ||||
		Reference in New Issue
	
	Block a user