fix: 500 error in php8

pull/276/head
qkqpttgf 2021-03-12 17:37:26 +08:00 committed by GitHub
parent bc66f43bea
commit 6230773e52
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -132,7 +132,7 @@ class Googledrive {
if (in_array(splitlast($item['name'],'.')[1], $exts['txt'])) { if (in_array(splitlast($item['name'],'.')[1], $exts['txt'])) {
if (!(isset($item['content'])&&$item['content']['stat']==200)) { if (!(isset($item['content'])&&$item['content']['stat']==200)) {
//if (!isset($item['downUrl'])) { //if (!isset($item['downUrl'])) {
$res = curl('GET', $item['webContentLink'], '', '', 1); $res = curl('GET', $item['webContentLink'], '', [], 1);
$weblink = $res['returnhead']['Location']; $weblink = $res['returnhead']['Location'];
//if ($weblink!==null) $item['downUrl'] = $weblink; //if ($weblink!==null) $item['downUrl'] = $weblink;
//else error_log1('Cant get link:' . json_encode($res, JSON_PRETTY_PRINT)); //else error_log1('Cant get link:' . json_encode($res, JSON_PRETTY_PRINT));