Skip to content
Snippets Groups Projects
Commit 9d1c5c85 authored by Robin Appelman's avatar Robin Appelman
Browse files

fix warning if no username is set in the cookie

parent 828a26c6
No related branches found
No related tags found
No related merge requests found
......@@ -69,14 +69,22 @@ elseif(isset($_POST["user"])) {
exit();
}
else {
OC_TEMPLATE::printGuestPage("", "login", array("error" => true, "username" => $_COOKIE["username"]));
if(isset($_COOKIE["username"])){
OC_TEMPLATE::printGuestPage("", "login", array("error" => true, "username" => $_COOKIE["username"]));
}else{
OC_TEMPLATE::printGuestPage("", "login", array("error" => true));
}
}
}
// For all others cases, we display the guest page :
else {
OC_APP::loadApps();
OC_TEMPLATE::printGuestPage("", "login", array("error" => false, "username" => $_COOKIE["username"]));
if(isset($_COOKIE["username"])){
OC_TEMPLATE::printGuestPage("", "login", array("error" => false, "username" => $_COOKIE["username"]));
}else{
OC_TEMPLATE::printGuestPage("", "login", array("error" => false));
}
}
?>
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment