From 5cceb8bc5c16343591b2deba59bfb90bedd8f725 Mon Sep 17 00:00:00 2001 From: Christian Weiske Date: Thu, 8 Feb 2018 22:25:28 +0100 Subject: [PATCH] No warnings on CLI anymore --- www/functions.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/www/functions.php b/www/functions.php index f6b5b1d..2d4e515 100644 --- a/www/functions.php +++ b/www/functions.php @@ -112,7 +112,9 @@ function playVideoOnDreambox($videoUrl, $dreamboxHost) ); $ret = file_get_contents($playUrl, false, $ctx); if ($ret !== false) { - header('HTTP/1.0 200 OK'); + if (php_sapi_name() != 'cli') { + header('HTTP/1.0 200 OK'); + } echo "Video play request sent to dreambox\n"; exit(0); } else { -- 2.30.2