diff --git a/http/raw.go b/http/raw.go index 5159d58f..cd05a1bc 100644 --- a/http/raw.go +++ b/http/raw.go @@ -182,9 +182,10 @@ func rawDirHandler(w http.ResponseWriter, r *http.Request, d *data, file *files. name = file.Name } else { // This should indicate that the fs root is the directory being downloaded, lookup its name - actual, err := file.Fs.Stat(".") - if err != nil { - return http.StatusInternalServerError, err + + actual, statErr := file.Fs.Stat(".") + if statErr != nil { + return http.StatusInternalServerError, statErr } name = actual.Name() }