MCPcopy Index your code
hub / github.com/CovenantSQL/CovenantSQL / GetTask

Function GetTask

cmd/cql-proxy/model/task.go:186–193  ·  view source on GitHub ↗

GetTask returns task with specified id and developer.

(db *gorp.DbMap, developer int64, id int64)

Source from the content-addressed store, hash-verified

184
185// GetTask returns task with specified id and developer.
186func GetTask(db *gorp.DbMap, developer int64, id int64) (t *Task, err error) {
187 err = db.SelectOne(&t,
188 `SELECT * FROM "task" WHERE "id" = ? AND "developer_id" = ? LIMIT 1`, id, developer)
189 if err != nil {
190 err = errors.Wrapf(err, "get task failed")
191 }
192 return
193}
194
195// UpdateTask save existing task object to database.
196func UpdateTask(db *gorp.DbMap, t *Task) (err error) {

Callers 2

getTaskFunction · 0.92
cancelTaskFunction · 0.92

Calls

no outgoing calls

Tested by

no test coverage detected