From a87530eada179ec7a5eea8a6238ede8c1d442e52 Mon Sep 17 00:00:00 2001 From: Florent Bruneau Date: Sun, 28 Feb 2010 17:01:15 +0100 Subject: [PATCH] Fix symbol clash between $user->watch fetched by default query and $user->watch() that check informations from the carnet. Signed-off-by: Florent Bruneau --- classes/user.php | 2 +- classes/userfilter.php | 2 +- include/notifs.inc.php | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/classes/user.php b/classes/user.php index b99bc3a..17ee862 100644 --- a/classes/user.php +++ b/classes/user.php @@ -432,7 +432,7 @@ class User extends PlUser $this->fillFromArray($watch); } - public function watch($type) + public function watchType($type) { $this->fetchWatchData(); return $this->watch_actions->hasFlag($type); diff --git a/classes/userfilter.php b/classes/userfilter.php index 3e89426..c76b93a 100644 --- a/classes/userfilter.php +++ b/classes/userfilter.php @@ -1253,7 +1253,7 @@ class UFC_WatchRegistration extends UFC_UserRelated { public function buildCondition(PlFilter &$uf) { - if (!$this->user->watch('registration')) { + if (!$this->user->watchType('registration')) { return PlFilterCondition::COND_FALSE; } $uids = $this->user->watchUsers(); diff --git a/include/notifs.inc.php b/include/notifs.inc.php index 1883e62..cda21a1 100644 --- a/include/notifs.inc.php +++ b/include/notifs.inc.php @@ -35,7 +35,7 @@ abstract class WatchOperation public function getCondition(PlUser &$user, $date) { $this->date = $date; - if (!$user->watch($this->flag)) { + if (!$user->watchType($this->flag)) { return new PFC_False(); } else { return $this->buildCondition($user); -- 2.1.4