fix(google_drive): allow download abuse file (#3217)

通过添加参数acknowledgeAbuse=true,对疑似风险文件直接下载
This commit is contained in:
Zayia 2023-02-01 19:43:36 +08:00 committed by GitHub
parent e1cd71616d
commit 080e6fb22a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -56,7 +56,7 @@ func (d *GoogleDrive) Link(ctx context.Context, file model.Obj, args model.LinkA
return nil, err
}
link := model.Link{
URL: url + "&alt=media",
URL: url + "&alt=media&acknowledgeAbuse=true",
Header: http.Header{
"Authorization": []string{"Bearer " + d.AccessToken},
},