fix bug
This commit is contained in:
parent
a52a9d67d1
commit
adf64dc6ff
1 changed files with 4 additions and 1 deletions
|
@ -68,16 +68,19 @@ func resetDailyTasks(cCtx *cli.Context) error {
|
||||||
log.Debug().Int("number of cards", len(cards)).Msg("Get Cards")
|
log.Debug().Int("number of cards", len(cards)).Msg("Get Cards")
|
||||||
|
|
||||||
for _, card := range cards {
|
for _, card := range cards {
|
||||||
|
log.Debug().Str("name", card.Name).Msg("Check")
|
||||||
foundLabel := false
|
foundLabel := false
|
||||||
for _, label := range card.Labels {
|
for _, label := range card.Labels {
|
||||||
if label.ID == dailyLabel.ID {
|
if label.ID == dailyLabel.ID {
|
||||||
foundLabel = true
|
foundLabel = true
|
||||||
|
log.Debug().Interface("card", card).Msg("Found daily card")
|
||||||
break
|
break
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if !foundLabel {
|
if !foundLabel {
|
||||||
break
|
log.Debug().Str("name", card.Name).Msg("Not match")
|
||||||
|
continue
|
||||||
}
|
}
|
||||||
|
|
||||||
err = card.MoveToList(todoList.ID, trello.Defaults())
|
err = card.MoveToList(todoList.ID, trello.Defaults())
|
||||||
|
|
Reference in a new issue