Sort working

This commit is contained in:
Henrique Dias
2017-07-03 18:49:08 +01:00
parent da3f043cfd
commit ce6557997a
3 changed files with 47 additions and 24 deletions

2
api.go
View File

@@ -268,7 +268,7 @@ func handleSortOrder(w http.ResponseWriter, r *http.Request, scope string) (sort
if sortCookie, sortErr := r.Cookie("sort"); sortErr == nil {
sort = sortCookie.Value
}
case "name", "size", "type":
case "name", "size":
http.SetCookie(w, &http.Cookie{
Name: "sort",
Value: sort,