Browse Source

修复bug (#271)

pull/273/head
小胡 9 months ago
committed by GitHub
parent
commit
3a454bbcce
No known key found for this signature in database GPG Key ID: B5690EEEBB952194
  1. 42
      core/class/dzz/dzz_error.php

42
core/class/dzz/dzz_error.php

@ -176,27 +176,7 @@ class dzz_error
ob_end_clean();
$gzip = getglobal('gzipcompress');
ob_start($gzip ? 'ob_gzhandler' : null);
//发送通知
$cur_url = $_SERVER['REQUEST_URI'];
foreach (C::t('user')->fetch_all_by_adminid(1) as $value) {
if ($value['uid'] != $_G['uid']) {
//发送通知
$notevars = array(
'from_id' => '0',
'from_idtype' => 'app',
'url' => $cur_url,
'author' => getglobal('username'),
'authorid' => getglobal('uid'),
'dataline' => dgmdate(TIMESTAMP),
'title' => '系统错误提醒',
'errormsg'=> '考虑到系统的稳定性'
);
$action = 'Error';
$type = 'Error_' . $value['uid'];
dzz_notification::notification_add($value['uid'], $type, $action, $notevars);
}
}
$host = $_SERVER['HTTP_HOST'];
$title = $type == 'db' ? 'Database' : 'System';
echo <<<EOT
@ -299,27 +279,7 @@ $exit && exit();
ob_end_clean();
ob_start();
//发送通知
$cur_url = $_SERVER['REQUEST_URI'];
foreach (C::t('user')->fetch_all_by_adminid(1) as $value) {
if ($value['uid'] != $_G['uid']) {
//发送通知
$notevars = array(
'from_id' => '0',
'from_idtype' => 'app',
'url' => $cur_url,
'author' => getglobal('username'),
'authorid' => getglobal('uid'),
'dataline' => dgmdate(TIMESTAMP),
'title' => '系统错误提醒',
'errormsg'=> '考虑到系统的稳定性'
);
$action = 'Error';
$type = 'Error_' . $value['uid'];
dzz_notification::notification_add($value['uid'], $type, $action, $notevars);
}
}
$host = $_SERVER['HTTP_HOST'];
$phpmsg = trim($phpmsg);
$title = 'Mobile '.($type == 'db' ? 'Database' : 'System');
@ -432,4 +392,4 @@ EOT;
error_log($message, 3, $file);
}
}
}
Loading…
Cancel
Save