fix(quark): upload commit bind resp
This commit is contained in:
parent
f127c959a1
commit
e07654299b
@ -14,6 +14,7 @@ type Addition struct {
|
|||||||
|
|
||||||
var config = driver.Config{
|
var config = driver.Config{
|
||||||
Name: "Quark",
|
Name: "Quark",
|
||||||
|
OnlyProxy: true,
|
||||||
}
|
}
|
||||||
|
|
||||||
func New() driver.Driver {
|
func New() driver.Driver {
|
||||||
|
@ -93,6 +93,7 @@ func (d *Quark) upPre(file model.FileStreamer, parentId string) (UpPreResp, erro
|
|||||||
"l_updated_at": now.UnixMilli(),
|
"l_updated_at": now.UnixMilli(),
|
||||||
"pdir_fid": parentId,
|
"pdir_fid": parentId,
|
||||||
"size": file.GetSize(),
|
"size": file.GetSize(),
|
||||||
|
//"same_path_reuse": true,
|
||||||
}
|
}
|
||||||
var resp UpPreResp
|
var resp UpPreResp
|
||||||
_, err := d.request("/file/upload/pre", http.MethodPost, func(req *resty.Request) {
|
_, err := d.request("/file/upload/pre", http.MethodPost, func(req *resty.Request) {
|
||||||
@ -208,7 +209,7 @@ x-oss-user-agent:aliyun-sdk-js/6.6.1 Chrome 98.0.4758.80 on Windows 10 64-bit
|
|||||||
var resp UpAuthResp
|
var resp UpAuthResp
|
||||||
_, err = d.request("/file/upload/auth", http.MethodPost, func(req *resty.Request) {
|
_, err = d.request("/file/upload/auth", http.MethodPost, func(req *resty.Request) {
|
||||||
req.SetBody(data)
|
req.SetBody(data)
|
||||||
}, nil)
|
}, &resp)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user