aboutsummaryrefslogtreecommitdiff
path: root/modules
diff options
context:
space:
mode:
Diffstat (limited to 'modules')
-rw-r--r--modules/lists/lists.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/modules/lists/lists.go b/modules/lists/lists.go
index 722d773..4152342 100644
--- a/modules/lists/lists.go
+++ b/modules/lists/lists.go
@@ -695,7 +695,7 @@ func (m *Module) removeGrilFromList(w http.ResponseWriter, r *http.Request, p ht
695 return 695 return
696 } 696 }
697 697
698 res, err := m.g.DB.QueryRow(`DELETE FROM grilist.lists_grils WHERE list_id=$1 AND gril_id=$2`, listID, grilID).Scan(&oldOrder) 698 err = m.g.DB.QueryRow(`DELETE FROM grilist.lists_grils WHERE list_id=$1 AND gril_id=$2`, listID, grilID).Scan(&oldOrder)
699 if err != nil { 699 if err != nil {
700 log.Println("error removing gril:", err) 700 log.Println("error removing gril:", err)
701 http.Error(w, "could not remove gril", 500) 701 http.Error(w, "could not remove gril", 500)
@@ -708,7 +708,7 @@ func (m *Module) removeGrilFromList(w http.ResponseWriter, r *http.Request, p ht
708 return 708 return
709 } 709 }
710 710
711 res, err = m.g.DB.Exec(`UPDATE grilist.lists_gril SET "order" = "order" - 1 WHERE list_id = $1 AND "order" > $2`, listID, oldOrder) 711 res, err := m.g.DB.Exec(`UPDATE grilist.lists_gril SET "order" = "order" - 1 WHERE list_id = $1 AND "order" > $2`, listID, oldOrder)
712 if err != nil { 712 if err != nil {
713 log.Println("error removing gril:", err) 713 log.Println("error removing gril:", err)
714 http.Error(w, "could not remove gril", 500) 714 http.Error(w, "could not remove gril", 500)