Fix recent regression when bridge is offline while initializing child things. (#12259)
Signed-off-by: Jacob Laursen <jacob-github@vindvejr.dk>
This commit is contained in:
parent
888cf00245
commit
1be50736e3
@ -79,7 +79,12 @@ public class HDPowerViewRepeaterHandler extends AbstractHubbedThingHandler {
|
||||
"@text/offline.conf-error.invalid-bridge-handler");
|
||||
return;
|
||||
}
|
||||
updateStatus(ThingStatus.UNKNOWN);
|
||||
ThingStatus bridgeStatus = bridge.getStatus();
|
||||
if (bridgeStatus == ThingStatus.ONLINE) {
|
||||
updateStatus(ThingStatus.UNKNOWN);
|
||||
} else {
|
||||
updateStatus(ThingStatus.OFFLINE, ThingStatusDetail.BRIDGE_OFFLINE);
|
||||
}
|
||||
scheduleRefreshJob();
|
||||
}
|
||||
|
||||
|
||||
@ -109,7 +109,12 @@ public class HDPowerViewShadeHandler extends AbstractHubbedThingHandler {
|
||||
"@text/offline.conf-error.invalid-bridge-handler");
|
||||
return;
|
||||
}
|
||||
updateStatus(ThingStatus.UNKNOWN);
|
||||
ThingStatus bridgeStatus = bridge.getStatus();
|
||||
if (bridgeStatus == ThingStatus.ONLINE) {
|
||||
updateStatus(ThingStatus.UNKNOWN);
|
||||
} else {
|
||||
updateStatus(ThingStatus.OFFLINE, ThingStatusDetail.BRIDGE_OFFLINE);
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user