Profile will now show the current users page when a username is not given in a get request.

This commit is contained in:
K. Nobel
2017-01-20 12:14:05 +01:00
parent 2f1bbd0a8e
commit 142bae139b

View File

@@ -42,11 +42,10 @@ function nicetime($date) {
}
if(empty($_GET["username"])) {
echo "User does not exist!";
return;
}
$userID = $_SESSION["userID"];
} else {
$userID = getUserID($_GET["username"]);
}
$user = selectUser($userID);
$profile_friends = selectAllFriends($userID);