aboutsummaryrefslogtreecommitdiff
path: root/main.go
diff options
context:
space:
mode:
Diffstat (limited to 'main.go')
-rw-r--r--main.go3
1 files changed, 2 insertions, 1 deletions
diff --git a/main.go b/main.go
index 826f624..18ae048 100644
--- a/main.go
+++ b/main.go
@@ -541,7 +541,8 @@ func download(w http.ResponseWriter, r *http.Request) {
sendError(w, r, err.Error(), http.StatusInternalServerError)
return
}
- f, err := os.Open(sel)
+ filePath := filepath.Join(baseDocDir, username, filepath.Base(sel))
+ f, err := os.Open(filePath)
if err != nil {
sendError(w, r, err.Error(), http.StatusInternalServerError)
return