diff options
author | Andrew Dolgov <[email protected]> | 2019-03-06 08:55:10 +0300 |
---|---|---|
committer | Andrew Dolgov <[email protected]> | 2019-03-06 08:55:10 +0300 |
commit | 6d0c9bb7846cee46ccdefae8b040e1981c826b68 (patch) | |
tree | 9845e4549dd061c22478fb08170f85b6d80d8b91 | |
parent | dfd3a4e581d10fa64f5b4f16e66fdb5c31b70444 (diff) |
only log sent mail if _LOG_SENT_MAIL is set
-rw-r--r-- | classes/mailer.php | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/classes/mailer.php b/classes/mailer.php index fbdf111a7..eea9f5ff6 100644 --- a/classes/mailer.php +++ b/classes/mailer.php @@ -19,7 +19,8 @@ class Mailer { $from_combined = $from_name ? "$from_name <$from_address>" : $from_address; $to_combined = $to_name ? "$to_name <$to_address>" : $to_address; - Logger::get()->log("Sending mail from $from_combined to $to_combined <$to_address> [$subject]: $message"); + if (defined('_LOG_SENT_MAIL') && _LOG_SENT_MAIL) + Logger::get()->log("Sending mail from $from_combined to $to_combined <$to_address> [$subject]: $message"); // HOOK_SEND_MAIL plugin instructions: // 1. return 1 or true if mail is handled |