summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorUrban Müller2014-04-22 15:44:28 +0200
committerUrban Müller2014-04-22 15:44:28 +0200
commit251da6fbd82b9e289430b330d403a318586da416 (patch)
tree38c29c61dc556afc93d2b43052a69d490edca29c
parent9c12f504e2a2a1b004493179697e8abb4dc25474 (diff)
downloaditools-251da6fbd82b9e289430b330d403a318586da416.tar.gz
itools-251da6fbd82b9e289430b330d403a318586da416.tar.bz2
itools-251da6fbd82b9e289430b330d403a318586da416.zip
remove unneccessary Body: when there are no other sections anyway
-rw-r--r--it.class5
1 files changed, 4 insertions, 1 deletions
diff --git a/it.class b/it.class
index f6d42ac..7813da9 100644
--- a/it.class
+++ b/it.class
@@ -208,7 +208,10 @@ static function error($p = array())
$p['body'] = "Body: " . getenv('HOSTNAME') . ":$datafn";
}
- $body = ($p['omitdebuginfo'] >= 2 ? "" : ($url && !$toscreen? "{$p['title']}\n\nUrl: $url\n\n" : "") . ($trace ? ($sendmail?"" :" ")."Trace: $trace\n\n" : "")) . ($p['body'] ? "Body:\n" . trim($p['body'])."\n\n" : "");
+ $body =
+ ($p['omitdebuginfo'] >= 2 ? "" : ($url && !$toscreen? "{$p['title']}\n\nUrl: $url\n\n" : "") .
+ ($trace ? ($sendmail ? "" : " ") . "Trace: $trace\n\n" : "")) .
+ ($p['body'] ? ($p['omitdebuginfo'] ? "" : "Body:\n") . trim($p['body'])."\n\n" : "");
if ($sendmail) # we're mailing: send maximum info
{