Merge pull request #19 from aelaraji/home_php

fix Undefined array key url in views/home.php
This commit is contained in:
sørenpeter 2024-12-08 18:34:22 +01:00 committed by GitHub
commit de78181cdc
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -24,9 +24,11 @@ $title = "Timeline for ".$title;
// Redirect guests to Profile view, if url not set til home twtxt.txt // Redirect guests to Profile view, if url not set til home twtxt.txt
if (!isset($_SESSION['password']) && ($_GET['url'] != $config['public_txt_url']) ) { if (!isset($_SESSION['password']) && (isset($_GET['url']))) {
header('Location: ./profile'); if ($_GET['url'] != $config['public_txt_url']) {
exit(); header('Location: ./profile');
exit();
}
} }
include_once 'partials/header.php'; include_once 'partials/header.php';
@ -43,4 +45,4 @@ if (isset($_SESSION['password'])) {
include_once 'partials/timeline.php'; include_once 'partials/timeline.php';
include_once 'partials/footer.php'; include_once 'partials/footer.php';