Lol, actually use the transaction that we make

This commit is contained in:
Aleksei Voronov 2023-10-15 17:19:15 +02:00
parent 96915ca986
commit fad2283aa2
1 changed files with 3 additions and 3 deletions

View File

@ -154,7 +154,7 @@ impl Database {
did: &str,
likely_country_of_living: &str,
) -> Result<bool> {
let transaction = self.connection_pool.begin().await?;
let mut transaction = self.connection_pool.begin().await?;
{
let mut params = Parameters::new();
@ -168,7 +168,7 @@ impl Database {
.to_string(),
)
.bind(did)
.execute(&self.connection_pool)
.execute(&mut *transaction)
.await?;
}
@ -183,7 +183,7 @@ impl Database {
)
.bind(likely_country_of_living)
.bind(did)
.execute(&self.connection_pool)
.execute(&mut *transaction)
.await?;
}