From 917a2dde09925199f9000b35e74fecb67af326ec Mon Sep 17 00:00:00 2001 From: emkael Date: Wed, 15 Mar 2017 16:26:18 +0100 Subject: * don't crash when there's no timezone selected for user --- app/frontend/facades/UserFacade.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'app') diff --git a/app/frontend/facades/UserFacade.php b/app/frontend/facades/UserFacade.php index 0bc5863..6a7feac 100644 --- a/app/frontend/facades/UserFacade.php +++ b/app/frontend/facades/UserFacade.php @@ -68,7 +68,7 @@ class UserFacade extends Facade { } public function getTimezonePreference(DbUser $user) { - if (!$user->IsGuest) { + if (!$user->IsGuest && $user->DbRecord->Timezone) { try { return new TimezoneDTO($user->DbRecord->Timezone); } catch(Exception $e) {} -- cgit v1.2.3