Skip to content

Commit

Permalink
Don't try to upload if previous attempt failed
Browse files Browse the repository at this point in the history
  • Loading branch information
bugadani committed Sep 28, 2023
1 parent f9dfc0d commit ee8f485
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/states/upload_or_store_measurement.rs
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,8 @@ pub async fn upload_or_store_measurement<const SIZE: usize>(
}
}

if can_upload {
// Only upload if we did not store.
if can_upload && !store_after_upload {
// Drop to free up 90kB of memory.
mem::drop(buffer);
upload_stored(board).await;
Expand Down

0 comments on commit ee8f485

Please sign in to comment.