Skip to content

Commit

Permalink
Calendar preferences MDL-23332 fix db call
Browse files Browse the repository at this point in the history
  • Loading branch information
danmarsden committed Jul 16, 2010
1 parent 6db3eee commit 5e58f69
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion calendar/preferences.php
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
require_once($CFG->dirroot.'/calendar/preferences_form.php');

$course = $site = get_site();
if (isset($SESSION->cal_course_referer)) {
if (!empty($SESSION->cal_course_referer)) {
$course = $DB->get_record('course', array('id'=>$SESSION->cal_course_referer), '*', MUST_EXIST);
}

Expand Down

0 comments on commit 5e58f69

Please sign in to comment.