diff --git a/pkg/models/task_position.go b/pkg/models/task_position.go index 9f558e67a..c00445ae6 100644 --- a/pkg/models/task_position.go +++ b/pkg/models/task_position.go @@ -47,11 +47,8 @@ func (tp *TaskPosition) TableName() string { } func (tp *TaskPosition) CanUpdate(s *xorm.Session, a web.Auth) (bool, error) { - pv, err := GetProjectViewByID(s, tp.ProjectViewID) - if err != nil { - return false, err - } - return pv.CanUpdate(s, a) + t := &Task{ID: tp.TaskID} + return t.CanUpdate(s, a) } // Update is the handler to update a task position