diff --git a/bundles/org.openhab.binding.lutron/src/main/java/org/openhab/binding/lutron/internal/discovery/LutronDeviceDiscoveryService.java b/bundles/org.openhab.binding.lutron/src/main/java/org/openhab/binding/lutron/internal/discovery/LutronDeviceDiscoveryService.java index 73be2c8c9c1a9..ce3295be910f8 100644 --- a/bundles/org.openhab.binding.lutron/src/main/java/org/openhab/binding/lutron/internal/discovery/LutronDeviceDiscoveryService.java +++ b/bundles/org.openhab.binding.lutron/src/main/java/org/openhab/binding/lutron/internal/discovery/LutronDeviceDiscoveryService.java @@ -130,6 +130,11 @@ private synchronized void asyncDiscoveryTask() { private void readDeviceDatabase() { Project project = null; + + if (bridgeHandler == null || bridgeHandler.getIPBridgeConfig() == null) { + logger.debug("Unable to get bridge config. Exiting."); + return; + } String discFileName = bridgeHandler.getIPBridgeConfig().discoveryFile; String address = "http://" + bridgeHandler.getIPBridgeConfig().ipAddress + "/DbXmlInfo.xml";