mirror of https://github.com/Xhofe/alist
* fix: correct the download url got by Cloudreve driver * fix: add an condition to the correctionpull/6346/head
parent
c3c5181847
commit
793a4ea6ca
|
@ -71,6 +71,9 @@ func (d *Cloudreve) Link(ctx context.Context, file model.Obj, args model.LinkArg
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return nil, err
|
return nil, err
|
||||||
}
|
}
|
||||||
|
if strings.HasPrefix(dUrl, "/api") {
|
||||||
|
dUrl = d.Address + dUrl
|
||||||
|
}
|
||||||
return &model.Link{
|
return &model.Link{
|
||||||
URL: dUrl,
|
URL: dUrl,
|
||||||
}, nil
|
}, nil
|
||||||
|
|
Loading…
Reference in New Issue