From d53b024bb12dcc57fddab168d810a1f8fde4385b Mon Sep 17 00:00:00 2001 From: Urban Müller Date: Mon, 21 Mar 2022 15:01:32 +0100 Subject: allow * in .diffnotice for no error mails --- it.class | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'it.class') diff --git a/it.class b/it.class index 5dbcdcd..14585ce 100644 --- a/it.class +++ b/it.class @@ -180,12 +180,12 @@ static function error($p = array(), $extra = null) else $url = $_SERVER['SCRIPT_NAME'] . " " . implode(" ", array_slice($GLOBALS['argv'], 1)) . " (pwd " . $_SERVER['PWD'] . ")"; - $gods = strtr(trim(@file_get_contents($GLOBALS['ULTRAHOME'] . "/.diffnotice")), array("\n"=>', ')); # NOPHPLINT + $authors = join(", ", it::grep('\*', (array)@it::cat($GLOBALS['ULTRAHOME'] . "/.diffnotice")->lines, ['invert' => true])); if (!$p['to']) unset($p['to']); # allow defaults to kick in $p += array( 'title' => "it::error", - 'to' => $gods ? $gods : (get_current_user() ? get_current_user() : $_SERVER['SERVER_ADMIN']), + 'to' => $authors ? $authors : (get_current_user() ? get_current_user() : $_SERVER['SERVER_ADMIN']), 'graceperiod' => 60, 'timewindow' => 25*3600, 'backtraceskip' => 1, -- cgit v1.2.3