diff --git a/src/poezio_logs.rs b/src/poezio_logs.rs index 4fe936d..f7e8269 100644 --- a/src/poezio_logs.rs +++ b/src/poezio_logs.rs @@ -81,7 +81,8 @@ pub fn parse_datetime(i: &str) -> IResult<&str, DateTime> { map_res(take(2usize), u32::from_str), tag("Z"), ))(i)?; - Ok((i, Utc.ymd(year, month, day).and_hms(hour, minute, second))) + // TODO: handle DST and other time transitions + Ok((i, Utc.with_ymd_and_hms(year, month, day, hour, minute, second).single().unwrap())) } pub fn parse_log_info(i: &str) -> IResult<&str, LogInfo> {