Skip to content

Commit

Permalink
Don't check affected rows when deleting task
Browse files Browse the repository at this point in the history
  • Loading branch information
sandreae committed Jul 25, 2023
1 parent 95a8776 commit 3a8424a
Showing 1 changed file with 2 additions and 6 deletions.
8 changes: 2 additions & 6 deletions aquadoggo/src/db/stores/task.rs
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ impl SqlStore {
};

// Remove task from database
let result = query(
query(
"
DELETE FROM
tasks
Expand All @@ -85,11 +85,7 @@ impl SqlStore {
.await
.map_err(|err| SqlStoreError::Transaction(err.to_string()))?;

if result.rows_affected() != 1 {
Err(SqlStoreError::Deletion("tasks".into()))
} else {
Ok(())
}
Ok(())
}

/// Returns "pending" tasks of the materialization service worker.
Expand Down

0 comments on commit 3a8424a

Please sign in to comment.