diff --git a/app/console b/app/console index 863a512cd8..a54ce32b48 160000 --- a/app/console +++ b/app/console @@ -1 +1 @@ -Subproject commit 863a512cd8c8c3e48e924ae4c4bb17f668309422 +Subproject commit a54ce32b481e59c5b3304e8907767ed6791a959c diff --git a/src/Appwrite/Detector/Detector.php b/src/Appwrite/Detector/Detector.php index 62f7a0a04b..61286835f5 100644 --- a/src/Appwrite/Detector/Detector.php +++ b/src/Appwrite/Detector/Detector.php @@ -77,10 +77,14 @@ class Detector */ public function getDevice(): array { + $deviceName = $this->getDetector()->getDeviceName(); + $deviceBrand = $this->getDetector()->getBrandName(); + $deviceModel = $this->getDetector()->getModel(); + return [ - 'deviceName' => $this->getDetector()->getDeviceName(), - 'deviceBrand' => $this->getDetector()->getBrandName(), - 'deviceModel' => $this->getDetector()->getModel(), + 'deviceName' => empty($deviceName) ? null : $deviceName, + 'deviceBrand' => empty($deviceBrand) ? null : $deviceBrand, + 'deviceModel' => empty($deviceModel) ? null : $deviceModel, ]; }