diff --git a/framework/base/router.class.php b/framework/base/router.class.php index c6b74e38c5..e8adf04cce 100644 --- a/framework/base/router.class.php +++ b/framework/base/router.class.php @@ -980,7 +980,7 @@ class baseRouter if($this->cookie->device == 'mobile') $this->clientDevice = 'mobile'; if($this->cookie->device == 'desktop') $this->clientDevice = 'desktop'; - if(strpos('mobile,desktop', $this->cookie->device) === false) + if(empty($this->cookie->device) || strpos('mobile,desktop', $this->cookie->device) === false) { $mobile = new mobile(); $this->clientDevice = ($mobile->isMobile() and !$mobile->isTablet()) ? 'mobile' : 'desktop';