Support multiple scan query strings at the same time

This commit is contained in:
Lode Hoste
2015-03-27 09:51:18 +01:00
parent fc0cb704f2
commit 2012ce02e8
4 changed files with 50 additions and 23 deletions

View File

@@ -685,8 +685,8 @@ func restPostScan(m *model.Model, w http.ResponseWriter, r *http.Request) {
qs := r.URL.Query()
folder := qs.Get("folder")
if folder != "" {
sub := qs.Get("sub")
err := m.ScanFolderSub(folder, sub)
subs := qs["sub"]
err := m.ScanFolderSubs(folder, subs)
if err != nil {
http.Error(w, err.Error(), 500)
}