Skip to content

Commit

Permalink
updated minute delay formatting
Browse files Browse the repository at this point in the history
  • Loading branch information
Kaya-Sem committed Sep 28, 2024
1 parent a7aa767 commit ed32f13
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion cmd/util.go
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,11 @@ func FormatDelay(seconds string) string {

minutes /= 60

// Return an empty string if there is no delay
if minutes == 0 {
return ""
}

// If the delay is 60 minutes or more, convert to hours and minutes
if minutes >= 60 {
hours := minutes / 60
Expand All @@ -34,7 +39,7 @@ func FormatDelay(seconds string) string {
return "+" + strconv.Itoa(hours) + "h"
}

return "+" + strconv.Itoa(minutes) + "m"
return "+" + strconv.Itoa(minutes)
}

func ShiftArgs(args []string) []string {
Expand Down

0 comments on commit ed32f13

Please sign in to comment.