Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Merge branch 'w40_MDL-41999_m24_userpw' of https://github.com/skodak/…

…moodle into MOODLE_24_STABLE
  • Loading branch information...
commit 4ae75c18473c4f0699e354b6ba0b8758e45e907b 2 parents d7788d6 + cf55843
@stronk7 stronk7 authored
Showing with 2 additions and 2 deletions.
  1. +1 −1  calendar/export.php
  2. +1 −1  calendar/view.php
View
2  calendar/export.php
@@ -125,7 +125,7 @@
$weekend = intval($CFG->calendar_weekend);
}
- $authtoken = sha1($USER->id . $USER->password . $CFG->calendar_exportsalt);
+ $authtoken = sha1($USER->id . $DB->get_field('user', 'password', array('id'=>$USER->id)). $CFG->calendar_exportsalt);
// Let's populate some vars to let "common tasks" be somewhat smart...
// If today it's weekend, give the "next week" option
$allownextweek = $weekend & (1 << $now['wday']);
View
2  calendar/view.php
@@ -153,7 +153,7 @@
echo $OUTPUT->single_button(new moodle_url('/calendar/managesubscriptions.php', array('course'=>$courseid)), get_string('managesubscriptions', 'calendar'));
}
if (isloggedin()) {
- $authtoken = sha1($USER->id . $USER->password . $CFG->calendar_exportsalt);
+ $authtoken = sha1($USER->id . $DB->get_field('user', 'password', array('id'=>$USER->id)) . $CFG->calendar_exportsalt);
$link = new moodle_url('/calendar/export_execute.php', array('preset_what'=>'all', 'preset_time'=>'recentupcoming', 'userid' => $USER->id, 'authtoken'=>$authtoken));
$icon = html_writer::empty_tag('img', array('src'=>$OUTPUT->pix_url('i/ical'), 'height'=>'14', 'width'=>'36', 'alt'=>get_string('ical', 'calendar'), 'title'=>get_string('quickdownloadcalendar', 'calendar')));
echo html_writer::tag('a', $icon, array('href'=>$link));
Please sign in to comment.
Something went wrong with that request. Please try again.