Fix moving tasks back into the empty (ID: 0) bucket

This commit is contained in:
kolaente 2020-04-20 23:08:38 +02:00
parent c69f0bf3cb
commit 68ab6d2e75
Signed by untrusted user: konrad
GPG Key ID: F40E70337AB24C9B
1 changed files with 6 additions and 1 deletions

View File

@ -664,10 +664,15 @@ func (t *Task) Update() (err error) {
if t.HexColor == "" {
ot.HexColor = ""
}
// Percent DOnw
// Percent Done
if t.PercentDone == 0 {
ot.PercentDone = 0
}
// Bucket ID
// Yes it is possible to move a task back into the empty bucket
if t.BucketID == 0 {
ot.BucketID = 0
}
_, err = x.ID(t.ID).
Cols("text",