Skip to content

Commit 8754f10

Browse files
authored
Replaced unneeded group by with distinct
1 parent 0d456a3 commit 8754f10

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

administrator/components/com_menus/models/fields/menuparent.php

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ protected function getOptions()
3939

4040
$db = JFactory::getDbo();
4141
$query = $db->getQuery(true)
42-
->select('a.id AS value, a.title AS text, a.level')
42+
->select('DISTINCT(a.id) AS value, a.title AS text, a.level')
4343
->from('#__menu AS a');
4444

4545
// Filter by menu type.
@@ -68,7 +68,6 @@ protected function getOptions()
6868
}
6969

7070
$query->where('a.published != -2')
71-
->group('a.id, a.title, a.level, a.lft, a.rgt, a.menutype, a.parent_id, a.published')
7271
->order('a.lft ASC');
7372

7473
// Get the options.

0 commit comments

Comments
 (0)