From 13486a5ada62e4355473ca01e07371c162951e84 Mon Sep 17 00:00:00 2001 From: Lukas Reschke Date: Thu, 12 Feb 2015 13:53:27 +0100 Subject: Migrate to SwiftMail Replaces the OC_Mail and phpmailer with SwiftMail allowing us to mock it properly. Fixes the unit test execution on master on local machines and https://github.com/owncloud/core/issues/12014 Conflicts: 3rdparty lib/private/server.php lib/public/iservercontainer.php tests/lib/mail.php tests/settings/controller/mailsettingscontrollertest.php Conflicts: 3rdparty lib/private/mail.php lib/private/server.php lib/public/iservercontainer.php settings/ajax/lostpassword.php settings/application.php --- settings/application.php | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'settings/application.php') diff --git a/settings/application.php b/settings/application.php index 6fe23447a72..ce47f155ebe 100644 --- a/settings/application.php +++ b/settings/application.php @@ -47,7 +47,7 @@ class Application extends App { $c->query('Config'), $c->query('UserSession'), $c->query('Defaults'), - $c->query('Mail'), + $c->query('Mailer'), $c->query('DefaultMailAddress') ); }); @@ -89,7 +89,7 @@ class Application extends App { $c->query('L10N'), $c->query('Logger'), $c->query('Defaults'), - $c->query('Mail'), + $c->query('Mailer'), $c->query('DefaultMailAddress'), $c->query('URLGenerator'), $c->query('OCP\\App\\IAppManager'), @@ -151,8 +151,8 @@ class Application extends App { $container->registerService('SubAdminFactory', function(IContainer $c) { return new SubAdminFactory(); }); - $container->registerService('Mail', function(IContainer $c) { - return new \OC_Mail; + $container->registerService('Mailer', function(IContainer $c) { + return $c->query('ServerContainer')->getMailer(); }); $container->registerService('Defaults', function(IContainer $c) { return new \OC_Defaults; -- cgit v1.2.3