From 3923b632de125a9ad7d675e5abc901650f732f1d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?C=C3=A9sar=20Su=C3=A1rez?= Date: Tue, 10 May 2016 18:15:43 +0200 Subject: [PATCH] Fix configuration management --- Mage/Command/BuiltIn/DeployCommand.php | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/Mage/Command/BuiltIn/DeployCommand.php b/Mage/Command/BuiltIn/DeployCommand.php index c97ae41..3296df5 100644 --- a/Mage/Command/BuiltIn/DeployCommand.php +++ b/Mage/Command/BuiltIn/DeployCommand.php @@ -590,8 +590,7 @@ class DeployCommand extends AbstractCommand implements RequiresEnvironment $projectName = $this->getConfig()->general('name', false); $projectEmail = $this->getConfig()->general('email', false); $notificationsEnabled = $this->getConfig()->general('notifications', false); - $ccEmail = $this->getConfig()->general('email_options.cc', null); - $bccEmail = $this->getConfig()->general('email_options.bcc', null); + $emailOptions = $this->getConfig()->general('email_options', array()); // We need notifications enabled, and a project name and email to send the notification if (!$projectName || !$projectEmail || !$notificationsEnabled) { @@ -604,12 +603,12 @@ class DeployCommand extends AbstractCommand implements RequiresEnvironment ->setLogFile(Console::getLogFile()) ->setEnvironment($this->getConfig()->getEnvironment()); - if ($ccEmail) { - $mailer->setCc($ccEmail); + if (isset($emailOptions['cc'])) { + $mailer->setCc($emailOptions['cc']); } - if ($bccEmail) { - $mailer->setBcc($bccEmail); + if (isset($emailOptions['bcc'])) { + $mailer->setBcc($emailOptions['bcc']); } $mailer->send($result);