This commit is contained in:
@@ -670,16 +670,13 @@ func registerPublicDownloads(mux *http.ServeMux, store filesvc.MeshStore, blobs
|
|||||||
}
|
}
|
||||||
|
|
||||||
// 3) Aus Mesh holen — EIGENER Timeout-Kontext, NICHT r.Context()
|
// 3) Aus Mesh holen — EIGENER Timeout-Kontext, NICHT r.Context()
|
||||||
ctx, cancel := context.WithTimeout(context.Background(), 2*time.Minute)
|
rrc, remoteName, _, _, err := meshNode.FetchBlobAny(context.Background(), id)
|
||||||
defer cancel()
|
|
||||||
rrc, remoteName, _, _, err := meshNode.FetchBlobAny(ctx, id)
|
|
||||||
if err != nil {
|
if err != nil {
|
||||||
http.NotFound(w, r)
|
http.NotFound(w, r)
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
defer rrc.Close()
|
defer rrc.Close()
|
||||||
|
|
||||||
// Dateiname bevorzugt vom Remote, sonst Metadaten-Name
|
|
||||||
filename := strings.TrimSpace(remoteName)
|
filename := strings.TrimSpace(remoteName)
|
||||||
if filename == "" {
|
if filename == "" {
|
||||||
filename = it.Name
|
filename = it.Name
|
||||||
|
|||||||
Reference in New Issue
Block a user