From 56f3539d06b819b05cea52785e9a96e76f30e6ab Mon Sep 17 00:00:00 2001 From: fiatjaf Date: Wed, 3 May 2023 19:49:07 -0300 Subject: [PATCH] nak event: fix created-at. --- event.go | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/event.go b/event.go index 7135d1c..165ba08 100644 --- a/event.go +++ b/event.go @@ -96,10 +96,12 @@ var event = &cli.Command{ } } - createdAt := c.String("created_at") + createdAt := c.String("created-at") ts := time.Now() if createdAt != "now" { if v, err := strconv.ParseInt(createdAt, 10, 64); err != nil { + return fmt.Errorf("failed to parse timestamp '%s': %w", createdAt, err) + } else { ts = time.Unix(v, 0) } }