aboutsummaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorJoas Schilling <coding@schilljs.com>2022-06-28 08:57:03 +0200
committerJoas Schilling <coding@schilljs.com>2022-06-28 08:57:03 +0200
commitf7eb14a9faa4a0799ec02f639572c8e3cfd1c01f (patch)
tree2da48bfd991db1760a74239d1da1ce05b6c6f9c7 /lib
parent2956da417841cb045796b5e0ff9ab50d1db4ca94 (diff)
downloadnextcloud-server-f7eb14a9faa4a0799ec02f639572c8e3cfd1c01f.tar.gz
nextcloud-server-f7eb14a9faa4a0799ec02f639572c8e3cfd1c01f.zip
Extend email logging
Signed-off-by: Joas Schilling <coding@schilljs.com>
Diffstat (limited to 'lib')
-rw-r--r--lib/private/Mail/Mailer.php3
1 files changed, 3 insertions, 0 deletions
diff --git a/lib/private/Mail/Mailer.php b/lib/private/Mail/Mailer.php
index 2f3480498be..991d1b202ec 100644
--- a/lib/private/Mail/Mailer.php
+++ b/lib/private/Mail/Mailer.php
@@ -196,6 +196,9 @@ class Mailer implements IMailer {
// Debugging logging
$logMessage = sprintf('Sent mail to "%s" with subject "%s"', print_r($message->getTo(), true), $message->getSubject());
+ if (!empty($failedRecipients)) {
+ $logMessage .= sprintf(' (failed for "%s")', print_r($failedRecipients, true));
+ }
$this->logger->debug($logMessage, ['app' => 'core']);
if ($debugMode && isset($mailLogger)) {
$this->logger->debug($mailLogger->dump(), ['app' => 'core']);