From a29666408c1ca175f2cc559388e2442b177523ad Mon Sep 17 00:00:00 2001 From: =?utf8?q?St=C3=A9phane=20Jacob?= Date: Thu, 20 Oct 2011 11:51:31 +0200 Subject: [PATCH] Updates aliases and MLs on new redirection addition (Closes #1549). MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Signed-off-by: Stéphane Jacob --- ChangeLog | 1 + include/emails.inc.php | 3 +++ 2 files changed, 4 insertions(+) diff --git a/ChangeLog b/ChangeLog index 3a4808d..58c2e75 100644 --- a/ChangeLog +++ b/ChangeLog @@ -23,6 +23,7 @@ Bug/Wish: * Email: - #1529: Stores and uses preferences for sending emails from site -JAC - #1516: Enables @polytechnique.edu adresses for old promotions -GLN + - #1549: Updates aliases and MLs on new redirection addition -JAC * Lists: - #1543: Displays no member in directory view for empty lists -JAC diff --git a/include/emails.inc.php b/include/emails.inc.php index a22adb5..2cf14d8 100644 --- a/include/emails.inc.php +++ b/include/emails.inc.php @@ -816,6 +816,9 @@ class Redirect XDB::execute('REPLACE INTO email_redirect_account (uid, redirect, flags, action) VALUES ({?}, {?}, \'active\', {?})', $this->user->id(), $email, $filter); + $listClient = new MMList(S::user()); + $listClient->change_user_email($this->user->forlifeEmail(), $new_email); + update_alias_user($this->user->forlifeEmail(), $new_email); if ($logger = S::v('log', null)) { // may be absent --> step4.php S::logger()->log('email_add', $email . ($this->user->id() != S::v('uid') ? " (admin on {$this->user->login()})" : "")); } -- 2.1.4