Skip to content

Commit

Permalink
Merge pull request #245 from HacDan/issue244
Browse files Browse the repository at this point in the history
Added check for project color non-existant
  • Loading branch information
sachaos authored Sep 13, 2023
2 parents af8652c + 2ed00d5 commit 7d31f4b
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion add_project.go
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,10 @@ func AddProject(c *cli.Context) error {
}

project.Name = c.Args().First()
project.Color = c.String("color")

if c.String("color") != "0" {
project.Color = c.String("color")
}
project.ItemOrder = c.Int("item-order")

if err := client.AddProject(context.Background(), project); err != nil {
Expand Down

0 comments on commit 7d31f4b

Please sign in to comment.