aboutsummaryrefslogtreecommitdiff
path: root/model/Schedule.php
diff options
context:
space:
mode:
authorMaZderMind2015-03-31 08:23:15 +0200
committerMaZderMind2015-03-31 08:23:15 +0200
commit72722fe3c6e88a683c07b5ee1989e61610d4b7aa (patch)
tree1a69816c88d80adac8d62b37eb1d22de6197aab1 /model/Schedule.php
parent1a050c087e8f2889b421992350c50fae75a9252b (diff)
Don't 500 when the Schedule is unreachable
Diffstat (limited to '')
-rw-r--r--model/Schedule.php8
1 files changed, 7 insertions, 1 deletions
diff --git a/model/Schedule.php b/model/Schedule.php
index e6aef7c..0eabc73 100644
--- a/model/Schedule.php
+++ b/model/Schedule.php
@@ -37,7 +37,13 @@ class Schedule extends ModelBase
return $schedule;
// download schedule-xml
- $schedule = $this->fetchSchedule();
+ try {
+ $schedule = $this->fetchSchedule();
+ }
+ catch(ErrorException $e)
+ {
+ return array();
+ }
$mapping = $this->getScheduleToRoomSlugMapping();
$program = array();