Code Duplication    Length = 4-7 lines in 2 locations

controller/admin_controller.php 2 locations

@@ 379-382 (lines=4) @@
376
	{
377
		$groups = array();
378
379
		foreach ($this->query_groups('autogroup_default_exempt = 1') as $row)
380
		{
381
			$groups[$row['group_id']] = $this->group_helper->get_name_string('full', $row['group_id'], $row['group_name'], $row['group_colour']);
382
		}
383
384
		return $groups;
385
	}
@@ 402-408 (lines=7) @@
399
		{
400
			$excluded_groups = json_decode($excluded_groups, true);
401
402
			foreach ($this->query_groups() as $row)
403
			{
404
				if (in_array($row['group_id'], $excluded_groups))
405
				{
406
					$groups[$row['group_id']] = $this->group_helper->get_name_string('full', $row['group_id'], $row['group_name'], $row['group_colour']);
407
				}
408
			}
409
		}
410
411
		return $groups;