Skip to content

Commit

Permalink
fix: layout format given to the date parser
Browse files Browse the repository at this point in the history
  • Loading branch information
galargh committed Nov 29, 2024
1 parent 7e9bc49 commit f33c24a
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions cmd/release/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -284,7 +284,7 @@ func main() {
}
}
if rc1Date != "" {
_, err := time.Parse("1999-12-31", rc1Date)
_, err := time.Parse("2006-01-02", rc1Date)
if err != nil {
return fmt.Errorf("invalid value for the 'rc1-date' flag. Must be a valid date (YYYY-MM-DD)")
}
Expand All @@ -300,7 +300,7 @@ func main() {
}
}
if stableDate != "" {
_, err := time.Parse("1999-12-31", stableDate)
_, err := time.Parse("2006-01-02", stableDate)
if err != nil {
return fmt.Errorf("invalid value for the 'stable-date' flag. Must be a valid date (YYYY-MM-DD)")
}
Expand Down

0 comments on commit f33c24a

Please sign in to comment.