Explorar o código

update specific hook_task, not all

Christopher Brickley %!s(int64=10) %!d(string=hai) anos
pai
achega
132590fab8
Modificáronse 1 ficheiros con 1 adicións e 1 borrados
  1. 1 1
      models/webhook.go

+ 1 - 1
models/webhook.go

@@ -230,7 +230,7 @@ func CreateHookTask(t *HookTask) error {
 
 // UpdateHookTask updates information of hook task.
 func UpdateHookTask(t *HookTask) error {
-	_, err := x.AllCols().Update(t)
+	_, err := x.Id(t.Id).AllCols().Update(t)
 	return err
 }