Details
-
Bug
-
Status: Closed
-
Major
-
Resolution: Fixed
-
2.5.1, 2.5.5, 2.6.2
-
MOODLE_25_STABLE, MOODLE_26_STABLE
-
MOODLE_25_STABLE, MOODLE_26_STABLE
-
wip-
MDL-40843-master -
-
BACKEND Sprint 11
Description
While working on MDL-34397 I was reviewing all cases of writing to course_modinfo objects (returned by get_fast_modinfo()). I found copy-pasted code for accessing module groups in following files:
- course/recent.php
- mod/assign/lib.php
- mod/assignment/lib.php
- mod/chat/lib.php
- mod/feedback/lib.php
- mod/forum/lib.php
- mod/quiz/lib.php
- mod/wiki/lib.php
- mod/workshop/lib.php
Of which assign, assignment, feedback, quiz and workshop access the $modinfo->groups incorrectly - this array is indexed by groupping id but acceed with module id as a key instead.
Also mod_glossary accesses groups incorrectly
Will try to understand the error it can cause and create tests.
Creating separate issue for it because it may need fixing in stable versions too.
Attachments
Issue Links
- blocks
-
MDL-44955 Behat tests for recent activity
-
- Closed
-
-
MDL-43742 Create API for recent activity
-
- Closed
-
- Discovered while testing
-
MDL-44794 get_groups(), get_groups_all() and groups_get_user_groups are not covered by unit tests
-
- Closed
-
- has a non-specific relationship to
-
MDL-29731 Recent activities block doesn't show new forum posts when forum is set to "separate groups"
-
- Closed
-
- has been marked as being related by
-
MDL-30781 Make course/lib.php::print_recent_activity() and associated callbacks deprecated
-
- Closed
-
- is blocked by
-
MDL-44362 Wrong id in recent activity
-
- Closed
-
-
MDL-40619 Simple behat test for quiz
-
- Closed
-
-
MDL-40872 Show recent submissions setting does not work in assignment
-
- Closed
-