Refactored/ streamlined UserSession code
Makes it easier to tell when a user is signed in
This commit is contained in:
@@ -1,7 +1,4 @@
|
||||
<?php
|
||||
include_once("./controller/UserSession.php");
|
||||
if(UserSession::isSessionValid()){
|
||||
Database::invalidateSession(UserSession::getSession()->token);
|
||||
}
|
||||
Database::invalidateSession($_COOKIE['usersession']);
|
||||
session_destroy();
|
||||
?>
|
||||
Reference in New Issue
Block a user