From e86ec5291c7a090ad14631f4eed6ed0d919a2d14 Mon Sep 17 00:00:00 2001 From: RunasSudo Date: Fri, 22 Nov 2024 18:54:41 +1100 Subject: [PATCH] Fix bug when confirming transaction deletion --- src/components/TransactionEditor.vue | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/components/TransactionEditor.vue b/src/components/TransactionEditor.vue index 3279a1a..14cff03 100644 --- a/src/components/TransactionEditor.vue +++ b/src/components/TransactionEditor.vue @@ -288,7 +288,7 @@ } async function deleteTransaction() { - if (!confirm('Are you sure you want to delete this transaction? This operation is irreversible.')) { + if (!await confirm('Are you sure you want to delete this transaction? This operation is irreversible.')) { return; } @@ -310,14 +310,14 @@ `DELETE FROM postings WHERE transaction_id = $1`, [transaction.id] - ) + ); // Delete transaction await dbTransaction.execute( `DELETE FROM transactions WHERE id = $1`, [transaction.id] - ) + ); await dbTransaction.commit();