projects
/
moodle.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
6fc6e43
)
Fixed a notice in isstudent()
author
moodler
<moodler>
Sun, 1 Aug 2004 06:21:59 +0000
(06:21 +0000)
committer
moodler
<moodler>
Sun, 1 Aug 2004 06:21:59 +0000
(06:21 +0000)
lib/moodlelib.php
patch
|
blob
|
history
diff --git
a/lib/moodlelib.php
b/lib/moodlelib.php
index 757c1375b368d4d05ccf77b400d3363c6b8493d2..addfe26122d1e64a84095b2ad002576c0bb0ad95 100644
(file)
--- a/
lib/moodlelib.php
+++ b/
lib/moodlelib.php
@@
-571,6
+571,10
@@
function isstudent($courseid, $userid=0) {
/// If course is site, is the user a confirmed user on the site?
global $USER;
+ if (empty($USER->id)) {
+ return false;
+ }
+
$site = get_site();
if ($courseid == $site->id) {
if (!$userid) {