From 279826e26fa5d655407913b8df63597e7f528ebc Mon Sep 17 00:00:00 2001 From: moodler Date: Wed, 28 Jan 2004 14:48:49 +0000 Subject: [PATCH] Yes, finally forum display preferences are preserved. :-) --- mod/forum/discuss.php | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/mod/forum/discuss.php b/mod/forum/discuss.php index 89af7e1fea..bd3c74dc0c 100644 --- a/mod/forum/discuss.php +++ b/mod/forum/discuss.php @@ -58,12 +58,14 @@ unset($SESSION->fromdiscussion); - forum_set_display_mode($mode); + if ($mode) { + set_user_preference("forum_displaymode", $mode); + } - $displaymode = $USER->mode; + $displaymode = get_user_preferences("forum_displaymode", $CFG->forum_displaymode); if ($parent) { - if (abs($USER->mode) == 1) { // If flat AND parent, then force nested display this time + if (abs($displaymode) == 1) { // If flat AND parent, then force nested display this time $displaymode = 3; } } else { -- 2.39.5