From 5a1cc8de9b13298d28afd6f1f1be02fafe2428b0 Mon Sep 17 00:00:00 2001 From: Bennet Becker Date: Tue, 3 Jan 2023 15:28:43 +0100 Subject: [PATCH] update usages of AutoSubmittedValue to AutoSubmitted::VALUE_ Signed-off-by: Bennet Becker --- .../CalDAV/Reminder/NotificationProvider/EmailProvider.php | 4 ++-- apps/settings/lib/Mailer/NewUserMailHelper.php | 4 ++-- apps/settings/tests/Mailer/NewUserMailHelperTest.php | 4 ++-- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/apps/dav/lib/CalDAV/Reminder/NotificationProvider/EmailProvider.php b/apps/dav/lib/CalDAV/Reminder/NotificationProvider/EmailProvider.php index 23e8ffc7e99..1cabf96489f 100644 --- a/apps/dav/lib/CalDAV/Reminder/NotificationProvider/EmailProvider.php +++ b/apps/dav/lib/CalDAV/Reminder/NotificationProvider/EmailProvider.php @@ -36,7 +36,7 @@ use OCP\IConfig; use OCP\IL10N; use OCP\IURLGenerator; use OCP\L10N\IFactory as L10NFactory; -use OCP\Mail\AutoSubmittedValue; +use OCP\Mail\Headers\AutoSubmitted; use OCP\Mail\IEMailTemplate; use OCP\Mail\IMailer; use OCP\IUser; @@ -132,7 +132,7 @@ class EmailProvider extends AbstractProvider { } $message->setTo([$emailAddress]); $message->useTemplate($template); - $message->setAutoSubmitted(AutoSubmittedValue::AUTO_GENERATED); + $message->setAutoSubmitted(AutoSubmitted::VALUE_AUTO_GENERATED); try { $failed = $this->mailer->send($message); diff --git a/apps/settings/lib/Mailer/NewUserMailHelper.php b/apps/settings/lib/Mailer/NewUserMailHelper.php index 5da1082455e..bfa34e1746a 100644 --- a/apps/settings/lib/Mailer/NewUserMailHelper.php +++ b/apps/settings/lib/Mailer/NewUserMailHelper.php @@ -35,7 +35,7 @@ use OCP\IConfig; use OCP\IURLGenerator; use OCP\IUser; use OCP\L10N\IFactory; -use OCP\Mail\AutoSubmittedValue; +use OCP\Mail\Header\AutoSubmitted; use OCP\Mail\IEMailTemplate; use OCP\Mail\IMailer; use OCP\Security\ICrypto; @@ -182,7 +182,7 @@ class NewUserMailHelper { $message->setTo([$email => $user->getDisplayName()]); $message->setFrom([$this->fromAddress => $this->themingDefaults->getName()]); $message->useTemplate($emailTemplate); - $message->setAutoSubmitted(AutoSubmittedValue::AUTO_GENERATED); + $message->setAutoSubmitted(AutoSubmitted::VALUE_AUTO_GENERATED); $this->mailer->send($message); } } diff --git a/apps/settings/tests/Mailer/NewUserMailHelperTest.php b/apps/settings/tests/Mailer/NewUserMailHelperTest.php index efb7ca9a29b..5c7d182d436 100644 --- a/apps/settings/tests/Mailer/NewUserMailHelperTest.php +++ b/apps/settings/tests/Mailer/NewUserMailHelperTest.php @@ -42,7 +42,7 @@ use OCP\IL10N; use OCP\IURLGenerator; use OCP\IUser; use OCP\L10N\IFactory; -use OCP\Mail\AutoSubmittedValue; +use OCP\Mail\Headers\AutoSubmitted; use OCP\Mail\IEMailTemplate; use OCP\Mail\IMailer; use OCP\Security\ICrypto; @@ -871,7 +871,7 @@ EOF; $message ->expects($this->once()) ->method('setAutoSubmitted') - ->with(AutoSubmittedValue::AUTO_GENERATED); + ->with(AutoSubmitted::VALUE_AUTO_GENERATED); $this->defaults ->expects($this->once()) ->method('getName') -- 2.39.5