Take a time struct instead of string.