From 5f8b5503d1fe973f009aa6911b4a6c8471e6d605 Mon Sep 17 00:00:00 2001 From: "Stefan A. Brannfjell" Date: Sat, 17 Jun 2017 23:39:43 +0200 Subject: [PATCH] Account activation by email small fix --- register.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/register.php b/register.php index 98f13ec..ec38648 100644 --- a/register.php +++ b/register.php @@ -116,11 +116,11 @@ if (isset($_GET['success']) && empty($_GET['success'])) { // Find a match $user = mysql_select_single("SELECT `id`, `active` FROM `znote_accounts` WHERE `account_id`='$auid' AND `activekey`='$akey' LIMIT 1;"); if ($user !== false) { - $user = $user['id']; - $active = $user['active']; + $user = (int) $user['id']; + $active = (int) $user['active']; // Enable the account to login if ($active == 0) { - mysql_update("UPDATE `znote_accounts` SET `active`='1' WHERE `id`='$user' LIMIT 1;"); + mysql_update("UPDATE `znote_accounts` SET `active`='1' WHERE `id`= $user LIMIT 1;"); } echo '

Congratulations!

Your account has been created. You may now login to create a character.

'; } else {