Skip to content

Commit 810524a

Browse files
authored
Merge pull request #232 from learnweb/fix/markunreadposts
Fix button that marks all posts as read
2 parents 3a3bca7 + ce7e781 commit 810524a

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

classes/readtracking.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -130,7 +130,7 @@ public static function moodleoverflow_mark_moodleoverflow_read($cm, $userid = nu
130130
$discussions = moodleoverflow_get_discussions_unread($cm);
131131

132132
// Iterate through all of this discussions.
133-
foreach ($discussions as $discussionid) {
133+
foreach ($discussions as $discussionid => $unread) {
134134
// Mark the discussion as read.
135135
$markedcheck = self::moodleoverflow_mark_discussion_read($discussionid, context_module::instance($cm->id), $userid);
136136
moodleoverflow_throw_exception_with_check($markedcheck !== true, 'markreadfailed');

0 commit comments

Comments
 (0)