fix multi-select files download error when filename contains '+' (#571)

Former-commit-id: fda2e75979b6d48ab77e1486d0d65375cae8ee03 [formerly 0ea1d769d4a591c522e7a642f386e3db579ce913] [formerly 230ee6abca47dd4a212d1481a294fc30972f3545 [formerly 7394f6b9bb]]
Former-commit-id: 3786998d5b87591db765e5388886e217a3c58dc8 [formerly c4954221ab23794024ced09d0f858c65d0d82c23]
Former-commit-id: 42bfe718742895fa9e03bf5dd5c1e53c826c510b
pull/726/head
helloray 2019-01-01 09:39:45 +08:00 committed by 1138-4EB
parent 8e4805ba69
commit b5ee82c943
1 changed files with 1 additions and 1 deletions

View File

@ -30,7 +30,7 @@ func downloadHandler(c *fb.Context, w http.ResponseWriter, r *http.Request) (int
if len(names) != 0 { if len(names) != 0 {
for _, name := range names { for _, name := range names {
// Unescape the name. // Unescape the name.
name, err := url.QueryUnescape(name) name, err := url.QueryUnescape(strings.Replace(name, "+", "%2B", -1))
if err != nil { if err != nil {
return http.StatusInternalServerError, err return http.StatusInternalServerError, err
} }