diff --git a/src/application/controller/login.php b/src/application/controller/login.php index a53687b..5bc3bcd 100644 --- a/src/application/controller/login.php +++ b/src/application/controller/login.php @@ -65,14 +65,17 @@ if (isset($_POST) && $_POST) { if ($_twister->importWallet($userName, $userPrivateKey)) { - // @TODO + // @TODO: add login time // Auth - if (!session_id()) { - - $_SESSION['username'] = $userName; + if (session_id()) { + session_destroy(); } + session_start(); + + $_SESSION['username'] = $userName; + // Redirect header('Location: ' . PROJECT_HOST, true, 302);