remove live data on error
Some checks failed
Create and publish a Docker image / build-and-push-image (push) Failing after 4m14s

This commit is contained in:
Nicholas Orlowsky 2025-11-22 16:21:57 -05:00
parent 798ae4aa1a
commit b6085d73fe
No known key found for this signature in database
GPG key ID: A9F3BA4C0AA7A70B

View file

@ -122,10 +122,11 @@ impl TripTrackingService {
tokio::spawn( async move {
loop {
let clonedx_state = Arc::clone(&cloned_state);
let res = Self::update_live_trips(clonedx_state).await;
let res = Self::update_live_trips(clonedx_state.clone()).await;
match res {
Err(err) => {
clonedx_state.lock().await.tracking_data = HashMap::new();
error!("{}", err);
}
_ => {}