diff options
author | Urban Müller | 2019-09-23 18:04:31 +0200 |
---|---|---|
committer | Urban Müller | 2019-09-23 18:04:31 +0200 |
commit | e04f87ccc76faaf1115601185d254f1694e438a7 (patch) | |
tree | 01cb8c20f56b435c5bfbd8870786ad32402b61a6 /it.class | |
parent | 9b1a57766f6e16511df15b7652b4e20b83853ef5 (diff) | |
download | itools-e04f87ccc76faaf1115601185d254f1694e438a7.tar.gz itools-e04f87ccc76faaf1115601185d254f1694e438a7.tar.bz2 itools-e04f87ccc76faaf1115601185d254f1694e438a7.zip |
mention machine in From: of it::error mails
Diffstat (limited to 'it.class')
-rw-r--r-- | it.class | 3 |
1 files changed, 2 insertions, 1 deletions
@@ -290,7 +290,8 @@ static function error($p = array()) if (!it::is_live() || array_diff($debugparams, it::match('[-\w]+', $GLOBALS['ULTRAHOME'], ['all' => true]), ["devel", "twin", "utf8check", gethostname()])) $type = mb_strtolower($type); - it::mail(['To' => $p['to'], 'Subject' => $type . substr($p['title'], 0, 160), 'Body' => $body, 'Cc' => $GLOBALS['it_defaultconfig']['error_cc'], 'forcemail' => !it::is_devel()]); + $from = trim(it::exec('echo \"$USER@`hostname`\" "<$USER@`dnsdomainname | grep . || hostname -f`>"')); + it::mail(['From' => $from, 'To' => $p['to'], 'Subject' => $type . substr($p['title'], 0, 160), 'Body' => $body, 'Cc' => $GLOBALS['it_defaultconfig']['error_cc'], 'forcemail' => !it::is_devel()]); $p['title'] = "Mail: " . $p['title']; } else if ($_SERVER['REMOTE_ADDR'] && EDC('edplain')) # toscreen mode: web |