Skip to content

Commit

Permalink
GHPR436 Fixed non respondents tab getting to many users
Browse files Browse the repository at this point in the history
  • Loading branch information
frederikmillingpytlick authored and mchurchward committed Dec 21, 2022
1 parent cd1b5a9 commit a6b0039
Showing 1 changed file with 1 addition and 9 deletions.
10 changes: 1 addition & 9 deletions locallib.php
Original file line number Diff line number Diff line change
Expand Up @@ -575,15 +575,7 @@ function questionnaire_get_incomplete_users($cm, $sid,
// First get all users who can complete this questionnaire.
$cap = 'mod/questionnaire:submit';
$fields = 'u.id, u.username';
if (!$allusers = get_users_by_capability($context,
$cap,
$fields,
$sort,
'',
'',
$group,
'',
true)) {
if (!$allusers = get_enrolled_users($context, $cap, $group, $fields, $sort)) {
return false;
}
$allusers = array_keys($allusers);
Expand Down

0 comments on commit a6b0039

Please sign in to comment.