Skip to content

Commit

Permalink
include_header: refactor
Browse files Browse the repository at this point in the history
  • Loading branch information
RedDragonWebDesign committed Jan 25, 2024
1 parent 9b5268d commit c2814ff
Showing 1 changed file with 2 additions and 5 deletions.
7 changes: 2 additions & 5 deletions src/themes/include_header.php
Original file line number Diff line number Diff line change
Expand Up @@ -14,11 +14,9 @@
}

// If user's user/pass cookies are broken, and they had previously selected "Remember Me", fix them
$hasMissingCookies = ! isset($_COOKIE['btUsername']) || ! isset($_COOKIE['btPassword']);
if (
(
! isset($_COOKIE['btUsername']) ||
! isset($_COOKIE['btPassword'])
) &&
$hasMissingCookies &&
isset($_SESSION['btRememberMe']) &&
$_SESSION['btRememberMe'] == 1 &&
isset($_SESSION['btUsername']) &&
Expand All @@ -28,7 +26,6 @@
setcookie("btPassword", $_SESSION['btPassword'], $COOKIE_EXP_TIME, $MAIN_ROOT);
}


$menuXML = new SimpleXMLElement(BASE_DIRECTORY."themes/".$THEME."/themeinfo.xml", 0, true);

// Check if user is logged in
Expand Down

0 comments on commit c2814ff

Please sign in to comment.