From 9cabedcfc2c95beda6a7455042bfab5b93ba5c0a Mon Sep 17 00:00:00 2001 From: Dirk Riestere Date: Thu, 9 Mar 2017 01:41:31 +0100 Subject: Fehler beim xml lesen behoben --- modules-available/locationinfo/inc/coursebackend.inc.php | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'modules-available/locationinfo/inc/coursebackend.inc.php') diff --git a/modules-available/locationinfo/inc/coursebackend.inc.php b/modules-available/locationinfo/inc/coursebackend.inc.php index ea2dcd44..8fc1f4f5 100644 --- a/modules-available/locationinfo/inc/coursebackend.inc.php +++ b/modules-available/locationinfo/inc/coursebackend.inc.php @@ -164,8 +164,11 @@ abstract class CourseBackend if ($this->getCacheTime() > 0 && $this->getRefreshTime() > 0) { $dbquery4 = Database::simpleQuery("SELECT locationid ,serverroomid, lastcalendarupdate FROM location_info WHERE serverid= :id", array('id' => $this->serverID)); foreach ($dbquery4->fetchAll(PDO::FETCH_COLUMN) as $row) { - if (strtotime($row['lastcalendarupdate']) > strtotime("-" . $this->getRefreshTime() . "seconds") && strtotime($row['lastcalendarupdate']) > strtotime("-" . $this->getCacheTime() . "seconds")) { - $sRoomIDs[$row['locationid']] = $row['serverroomid']; + if(isset($row['lastcalendarupdate'])) { + $lastUpdate = $row['lastcalendarupdate']; + if (strtotime($lastUpdate) > strtotime("-" . $this->getRefreshTime() . "seconds") && strtotime($lastUpdate) > strtotime("-" . $this->getCacheTime() . "seconds")) { + $sRoomIDs[$row['locationid']] = $row['serverroomid']; + } } } } -- cgit v1.2.3-55-g7522