fix tests (proper timezone), proper spacing
All checks were successful
CI/CD Pipeline / test (push) Successful in 12m39s
CI/CD Pipeline / deploy-staging (push) Has been skipped
CI/CD Pipeline / deploy-main (push) Has been skipped

This commit is contained in:
2024-04-15 21:32:16 +02:00
parent d070c7731a
commit 8315a27ea8
3 changed files with 5 additions and 5 deletions

View File

@ -505,7 +505,7 @@ ORDER BY departure DESC
let dep = NaiveDateTime::parse_from_str(&log.departure, "%Y-%m-%dT%H:%M").unwrap();
let arr = NaiveDateTime::parse_from_str(&log.arrival, "%Y-%m-%dT%H:%M").unwrap();
if arr.timestamp() <= dep.timestamp() {
if arr.timestamp() < dep.timestamp() {
return Err(LogbookUpdateError::ArrivalNotAfterDeparture);
}
let today = Local::now().date_naive();