Skip to content

Commit

Permalink
Delete file after upload
Browse files Browse the repository at this point in the history
  • Loading branch information
bugadani committed Sep 28, 2023
1 parent 7989153 commit 2922e4c
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/states/upload_or_store_measurement.rs
Original file line number Diff line number Diff line change
Expand Up @@ -274,6 +274,9 @@ async fn upload_stored(board: &mut Board) -> bool {
}

info!("Uploaded {}", name);
if let Err(e) = file.delete(storage).await {
warn!("Failed to delete file: {}", e);
}
}
Ok(_) | Err(StorageError::InsufficientBuffer) => {
// not a measurement file, ignore
Expand Down

0 comments on commit 2922e4c

Please sign in to comment.