legs: fix sorting by departure time

Reported-by: StingWest
Signed-off-by: diditclear <didyourupgradeclear@gmail.com>