Merge branch 'platal-0.10.0'
[platal.git] / include / emails.inc.php
index db87791..ec7946d 100644 (file)
@@ -1,6 +1,6 @@
 <?php
 /***************************************************************************
- *  Copyright (C) 2003-2008 Polytechnique.org                              *
+ *  Copyright (C) 2003-2009 Polytechnique.org                              *
  *  http://opensource.polytechnique.org/                                   *
  *                                                                         *
  *  This program is free software; you can redistribute it and/or modify   *
@@ -553,7 +553,7 @@ class Redirect
     {
         XDB::execute("UPDATE  emails
                          SET  flags = 'disable'
-                       WHERE  flags = 'active' AND uid = {?}", $this->user->id);
+                       WHERE  flags = 'active' AND uid = {?}", $this->user->id());
         foreach ($this->emails as &$mail) {
             if ($mail->active && $mail->has_disable()) {
                 $mail->disabled = true;
@@ -569,7 +569,7 @@ class Redirect
     {
         XDB::execute("UPDATE  emails
                          SET  flags = 'active'
-                       WHERE  flags = 'disable' AND uid = {?}", $this->user->id);
+                       WHERE  flags = 'disable' AND uid = {?}", $this->user->id());
         foreach ($this->emails as &$mail) {
             if ($mail->disabled) {
                 $mail->active   = true;