From 80cc7d28b827b1fa18382acec84b54a17b3ca989 Mon Sep 17 00:00:00 2001 From: =?utf8?q?St=C3=A9phane=20Jacob?= Date: Tue, 18 Oct 2011 10:28:49 +0200 Subject: [PATCH] Fixes misplaced assignation. MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Signed-off-by: Stéphane Jacob --- modules/profile/general.inc.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/profile/general.inc.php b/modules/profile/general.inc.php index 2ca66c6..93302c9 100644 --- a/modules/profile/general.inc.php +++ b/modules/profile/general.inc.php @@ -482,6 +482,7 @@ class ProfileSettingHobby implements ProfileSetting public function value(ProfilePage $page, $field, $value, &$success) { + $success = true; if (is_null($value)) { $value = XDB::fetchAllAssoc('SELECT type, text, pub FROM profile_hobby @@ -491,7 +492,6 @@ class ProfileSettingHobby implements ProfileSetting if (!is_array($value)) { return array(); } - $success = true; foreach($value as $i => &$hobby) { $hobby['text'] = trim($hobby['text']); if (!$hobby['text'] ||!in_array($hobby['type'], self::$type)) { -- 2.1.4