diff --git a/phpBB/includes/functions_display.php b/phpBB/includes/functions_display.php index 53d485cae3..498d468983 100644 --- a/phpBB/includes/functions_display.php +++ b/phpBB/includes/functions_display.php @@ -729,6 +729,11 @@ function display_forums($root_data = '', $display_moderators = true, $return_mod */ function generate_forum_rules(&$forum_data) { + if ($forum_data['forum_rules']) + { + $forum_data['forum_rules'] = generate_text_for_display($forum_data['forum_rules'], $forum_data['forum_rules_uid'], $forum_data['forum_rules_bitfield'], $forum_data['forum_rules_options']); + } + if (!$forum_data['forum_rules'] && !$forum_data['forum_rules_link']) { return; @@ -736,11 +741,6 @@ function generate_forum_rules(&$forum_data) global $template; - if ($forum_data['forum_rules']) - { - $forum_data['forum_rules'] = generate_text_for_display($forum_data['forum_rules'], $forum_data['forum_rules_uid'], $forum_data['forum_rules_bitfield'], $forum_data['forum_rules_options']); - } - $template->assign_vars(array( 'S_FORUM_RULES' => true, 'U_FORUM_RULES' => $forum_data['forum_rules_link'],