Fix registration bug

This commit is contained in:
Matej Bačo
2023-05-12 08:45:28 +02:00
parent eb764871db
commit cddc40449a
2 changed files with 8 additions and 4 deletions
+7 -3
View File
@@ -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,
];
}