Skip to content

Commit

Permalink
Update Login.php
Browse files Browse the repository at this point in the history
SonarQube fixing -  else if
  • Loading branch information
rcarvello authored Oct 2, 2023
1 parent 46acd5b commit b1d93da
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions controllers/common/Login.php
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ protected function autorun($parameters = null)
// Handles login form submission
if (isset($_POST["login_form_do_cancel"])){
header("Location: " . SITEURL);
} else if (isset($_POST["login_form_do_login"])) {
} elseif (isset($_POST["login_form_do_login"])) {
$this->configCookies();
$email = $_POST["email"];
$password = $_POST["password"];
Expand All @@ -61,7 +61,7 @@ protected function autorun($parameters = null)
$returnPage = (isset($_GET["return_link"])) ? SITEURL . "/" . $_GET["return_link"] : SITEURL;
header("Location:". $returnPage);
}
} else if (isset($_POST["login_form_do_logout"])) {
} elseif (isset($_POST["login_form_do_logout"])) {
$this->model->logout();
header("Location:". SITEURL);
} else {
Expand Down

0 comments on commit b1d93da

Please sign in to comment.