I wonder if the function quiz_access_to_score() in the quiz.module (line 230) is necessary.
When I block code as shown below, The notice disappears. And, important, the user can still view his own quiz results only. Also after flushing cache and rebuilding permissions.

/**
* Helper function to determine if a user has access to score a quiz.
*
* @param $quiz_creator
* uid of the quiz creator.
*/
function quiz_access_to_score($quiz_creator = NULL) {
global $user;
if ($quiz_creator == NULL) {
$quiz = quiz_get_quiz_from_menu();
// $quiz_creator = $quiz->uid;
}
if (user_access('score any quiz')) {
return TRUE;
}
// if (user_access('score own quiz') && $user->uid == $quiz_creator) {
return TRUE;
// }
}

Comments

falcon’s picture

Priority: Normal » Major

We should look into this

falcon’s picture

Issue summary: View changes

small text improvement

djdevin’s picture

Issue summary: View changes
Status: Active » Closed (outdated)