Skip to content

Commit

Permalink
Minor refactor
Browse files Browse the repository at this point in the history
  • Loading branch information
brundonsmith committed Jun 19, 2024
1 parent 3b8c547 commit 21a2633
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion back-end/routes/v1/auth.ts
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ export default function register(router: Router) {
)

const account = await withDBConnection(async (db) => {
const existingAccount = (await db.queryObject<Tables['account']>`SELECT * FROM account WHERE email_address = ${email_address}`).rows[0]
const existingAccount = (await db.queryTable('account', { where: ['email_address', '=', email_address] }))[0]

if (existingAccount != null && existingAccount.password_hash == null && existingAccount.password_salt == null) {
return (await db.updateTable('account', {
Expand Down

0 comments on commit 21a2633

Please sign in to comment.