Skip to content

Commit

Permalink
UPDATE add unkown device
Browse files Browse the repository at this point in the history
  • Loading branch information
ggottwald committed Nov 17, 2018
1 parent 2d92b74 commit 5a4ba02
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion src/Models/Gateway.php
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,14 @@ public function handleMessage($response)
$subDevice = new Cube(['sid' => $response->sid]);
break;
default:
return false;
$subDevice = new Class(['sid' => $response->sid]) extends Subdevice
{
public function __construct(array $attributes = [])
{
$this->type = 'unknown';
parent::__construct($attributes);
}
};
}

if (isset($subDevice)) {
Expand Down

0 comments on commit 5a4ba02

Please sign in to comment.