Update common.php

This commit is contained in:
qkqpttgf 2020-03-04 19:11:12 +08:00 committed by GitHub
parent 8782abd69c
commit 1d43e05e28
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -622,7 +622,7 @@ function main($path)
if (getConfig('proxydownload')) {
$header = [];
if (isset($_SERVER['HTTP_RANGE'])) $header = [ 'Range' => $_SERVER['HTTP_RANGE'] ];
else $header = [ 'Range' => 'Range: bytes=0-1048575' ];
//else $header = [ 'Range' => 'Range: bytes=0-1048575' ];
$response = curl_request( $files['@microsoft.graph.downloadUrl'], '', $header );
return output( base64_encode($response['body']), $response['stat'], ['Content-Type' => 'application/octet-stream'], true );
} else return output('', 302, [ 'Location' => $files['@microsoft.graph.downloadUrl'] ]);