From 0e24009fe9d60b33e6e79fafee349c1e049eb2ea Mon Sep 17 00:00:00 2001 From: Lunny Xiao Date: Wed, 9 Mar 2022 08:47:58 +0800 Subject: [PATCH] Fix create milestone with deadline bug (#462) Fix #461 Reviewed-on: https://gitea.com/gitea/tea/pulls/462 Reviewed-by: Norwin Reviewed-by: 6543 <6543@obermui.de> Co-authored-by: Lunny Xiao Co-committed-by: Lunny Xiao --- cmd/milestones/create.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cmd/milestones/create.go b/cmd/milestones/create.go index 0a3001b..e0f41d2 100644 --- a/cmd/milestones/create.go +++ b/cmd/milestones/create.go @@ -55,7 +55,7 @@ func runMilestonesCreate(cmd *cli.Context) error { deadline := &time.Time{} if date != "" { t, err := dateparse.ParseAny(date) - if err == nil { + if err != nil { return err } deadline = &t