Uploaded image for project: 'Moodle'
  1. Moodle
  2. MDL-9520

groups_groupids_to_groups should return groups indexed by group ID

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 1.8, 1.9
    • Fix Version/s: 1.8.1
    • Component/s: Groups
    • Labels:
      None
    • Affected Branches:
      MOODLE_18_STABLE, MOODLE_19_STABLE
    • Fixed Branches:
      MOODLE_18_STABLE

      Description

      This function, which is relied on by user_group and get_groups, returns a list of group objects that correspond to the group ID array given. All fine except that the array is just indexed 0,1, etc. but it should be indexed by group ID.

      Some usages of get_groups etc in legacy code (we noticed one in quiz results) rely on the array keys being IDs so these probably don't work at present. It might need more checking to ensure this is the expected behaviour throughout, but otherwise this fix should be checked in.

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                skodak Petr Skoda
                Reporter:
                quen Sam Marshall
                Tester:
                Nobody
                Participants:
                Component watchers:
                Andrew Nicols, Mathew May, Michael Hawkins, Shamim Rezaie, Simey Lameze
              • Votes:
                0 Vote for this issue
                Watchers:
                0 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:
                  Fix Release Date:
                  11/Jun/07