Fix sensor discover when device_id is omitted (#16389)

This commit is contained in:
Tony Murray
2024-09-12 11:20:50 -05:00
committed by GitHub
parent 4c72856046
commit 00d6fc64d6
+1
View File
@@ -47,6 +47,7 @@ class Sensor
public function discover(\App\Models\Sensor $sensor): static
{
$sensor->device_id ??= \DeviceCache::getPrimary()->device_id;
$this->models->push($sensor);
$this->discovered[$sensor->syncGroup()] = false;