Skip to content

Commit

Permalink
No need to reset the statement when dropping.
Browse files Browse the repository at this point in the history
  • Loading branch information
Julius de Bruijn committed Jun 25, 2020
1 parent 745a32a commit 363dbfb
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions sqlx-core/src/sqlite/connection/executor.rs
Original file line number Diff line number Diff line change
Expand Up @@ -29,10 +29,7 @@ fn prepare<'a>(

if !statements.contains_key(query) {
let statement = SqliteStatement::prepare(conn, query, false)?;

if let Some(mut statement) = statements.insert(query, statement) {
statement.reset();
}
statements.insert(query, statement);
}

let statement = statements.get_mut(query).unwrap();
Expand Down

0 comments on commit 363dbfb

Please sign in to comment.