You are here

function _quiz_user_results_access in Quiz 7.4

Same name and namespace in other branches
  1. 8.4 quiz.module \_quiz_user_results_access()
  2. 6.4 quiz.module \_quiz_user_results_access()
  3. 7.6 quiz.module \_quiz_user_results_access()
  4. 7 quiz.module \_quiz_user_results_access()

Determine who should have access to the My results tab.

1 string reference to '_quiz_user_results_access'
quiz_menu in ./quiz.module
Implements hook_menu().

File

./quiz.module, line 4145
Quiz Module

Code

function _quiz_user_results_access($user_id) {
  global $user;
  return $user_id == $user->uid && user_access('view own quiz results') || user_access('view any quiz results');
}