From 659ef11451d2cc53577585cd04e282a1914579eb Mon Sep 17 00:00:00 2001 From: slonkazoid Date: Sun, 29 Dec 2024 22:46:55 +0300 Subject: [PATCH] update conflict resolution --- blogin.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/blogin.sh b/blogin.sh index ebe8381..0bc815d 100644 --- a/blogin.sh +++ b/blogin.sh @@ -60,7 +60,7 @@ case "$action" in exit fi { - query="SELECT password FROM users WHERE username=$(escape_sql_str "$username")" + query="SELECT password FROM users WHERE username=$(escape_sql_str "$username") ON CONFLICT (username) DO SET password=excluded.password" row=$(db_row "$query") if [[ "$row" == "null" ]]; then hash=$(printf '%s' "$password" | argon2_hash)