fix autoscroll
All checks were successful
Create and publish a Docker image / build-and-push-image (push) Successful in 5m26s

This commit is contained in:
Nicholas Orlowsky 2025-10-07 19:02:30 -04:00
parent a9dc145514
commit 12e4f08a6a
No known key found for this signature in database
GPG key ID: A9F3BA4C0AA7A70B
2 changed files with 26 additions and 10 deletions

View file

@ -82,7 +82,7 @@ pub fn build_timetables(
});
for trip in direction_trips.clone() {
if let Some(last) = trip.schedule.last() {
if let Some(last) = trip.schedule.iter().max_by_key(|x| x.arrival_time) {
if next_id == None && i64::from(seconds_since_midnight) < last.arrival_time {
next_id = Some(last.trip_id.clone());
}