diff --git a/classes/backend.php b/classes/backend.php index bd4686aa9..4be38e0c4 100644 --- a/classes/backend.php +++ b/classes/backend.php @@ -7,14 +7,18 @@ class Backend extends Handler { } function digestTest() { - header("Content-type: text/html"); + if (isset($_SESSION['uid'])) { + header("Content-type: text/html"); - $rv = Digest::prepare_headlines_digest($_SESSION['uid'], 1, 1000); + $rv = Digest::prepare_headlines_digest($_SESSION['uid'], 1, 1000); - print "
".$rv[3].""; + print "
".$rv[3].""; + } else { + print error_json(6); + } } private function display_main_help() {