Browse Source

Moderator groups weren't shown in the moderators list on the board index

Signed-off-by: Michael Eshom <[email protected]>
Michael Eshom 12 years ago
parent
commit
b64c4a9185
1 changed files with 6 additions and 0 deletions
  1. 6 0
      Sources/Subs-BoardIndex.php

+ 6 - 0
Sources/Subs-BoardIndex.php

@@ -176,6 +176,12 @@ function getBoardIndex($boardIndexOptions)
 				);
 				$this_category[$row_board['id_board']]['link_moderator_groups'][] = '<a href="' . $scripturl . '?action=groups;sa=members;group=' . $row_board['id_moderator_group'] . '" title="' . $txt['board_moderator'] . '">' . $row_board['mod_group_name'] . '</a>';
 			}
+			
+			// Merge the two lists of moderators
+			if (!empty($this_category[$row_board['id_board']]['link_moderator_groups']))
+			{
+				$this_category[$row_board['id_board']]['link_moderators'] = array_merge($this_category[$row_board['id_board']]['link_moderators'], $this_category[$row_board['id_board']]['link_moderator_groups']);
+			}
 		}
 		// Found a child board.... make sure we've found its parent and the child hasn't been set already.
 		elseif (isset($this_category[$row_board['id_parent']]['children']) && !isset($this_category[$row_board['id_parent']]['children'][$row_board['id_board']]))