Skip to content

Commit

Permalink
Merge branch 'MDL-48088-master' of git://github.com/jethac/moodle
Browse files Browse the repository at this point in the history
  • Loading branch information
danpoltawski committed Dec 22, 2014
2 parents c67c00a + 08a4f93 commit 0a6ac6e
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions calendar/lib.php
Original file line number Diff line number Diff line change
Expand Up @@ -1931,6 +1931,9 @@ function calendar_normalize_tz($tz) {
case('Japan Standard Time'):
$tz = 'Asia/Tokyo';
break;
case('Romance Standard Time'):
$tz = 'Europe/Brussels';
break;
}
return $tz;
}
Expand Down Expand Up @@ -2971,6 +2974,7 @@ function calendar_add_icalendar_event($event, $courseid, $subscriptionid, $timez
} else {
$endtz = isset($event->properties['DTEND'][0]->parameters['TZID']) ? $event->properties['DTEND'][0]->parameters['TZID'] :
$timezone;
$endtz = calendar_normalize_tz($endtz);
$eventrecord->timeduration = strtotime($event->properties['DTEND'][0]->value . ' ' . $endtz) - $eventrecord->timestart;
}

Expand Down

0 comments on commit 0a6ac6e

Please sign in to comment.