Permalink
Browse files

MDL-33340 completion: Incorrect logic in hidden field check

Credit to Jody Steele
  • Loading branch information...
1 parent b0f20bc commit 53459511a96871583f6ed21517372b9bf4cbd96a @ankitagarwal ankitagarwal committed with danpoltawski Jun 25, 2012
Showing with 1 addition and 1 deletion.
  1. +1 −1 report/outline/index.php
View
@@ -42,7 +42,7 @@
$showlastaccess = true;
$hiddenfields = explode(',', $CFG->hiddenuserfields);
-if (array_search('lastaccess', $hiddenfields) and !has_capability('moodle/user:viewhiddendetails', $context)) {
+if (array_search('lastaccess', $hiddenfields) !== false and !has_capability('moodle/user:viewhiddendetails', $context)) {
$showlastaccess = false;
}

0 comments on commit 5345951

Please sign in to comment.