From c652e5a2ebbe5ed589d637301f3f26383e485bc4 Mon Sep 17 00:00:00 2001 From: Urban Müller Date: Thu, 28 Jun 2018 01:46:06 +0200 Subject: fix mute mode --- it.class | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'it.class') diff --git a/it.class b/it.class index 01fe916..8725f3b 100644 --- a/it.class +++ b/it.class @@ -228,8 +228,8 @@ static function error($p = array()) { $lastsentfn = "/tmp/alertdata/it_error_mailsent_" . urlencode($p['blockmailid']); clearstatcache(); - $sendmail = time() - max(@filemtime($lastsentfn), it_cache::get($lastsentfn, ['distributed' => true])) > $p['blockmail']; - if ($sendmail && !it_cache::get('it_error_mute_' . $GLOBALS['ULTRASITE'], [ 'distributed' => true ])) + $sendmail = time() - max(@filemtime($lastsentfn), it_cache::get($lastsentfn, ['distributed' => true])) > $p['blockmail'] && !it_cache::get('it_error_mute_' . $GLOBALS['ULTRASITE'], ['distributed' => true]); + if ($sendmail) { @unlink($lastsentfn); @touch($lastsentfn); -- cgit v1.2.3