mirror of
https://github.com/hyperion-project/hyperion.ng.git
synced 2023-10-10 13:36:59 +02:00
Throw Execption as "return false" is not handled
if no hostname configured nor device was discovered
This commit is contained in:
parent
c16ecde539
commit
5b17924cdf
@ -102,8 +102,7 @@ bool LedDeviceNanoleaf::init(const QJsonObject &deviceConfig) {
|
|||||||
if ( _hostname.isEmpty() )
|
if ( _hostname.isEmpty() )
|
||||||
//Discover Nanoleaf device
|
//Discover Nanoleaf device
|
||||||
if ( !discoverNanoleafDevice() ) {
|
if ( !discoverNanoleafDevice() ) {
|
||||||
Error(_log, "No target IP defined nor Nanoleaf device discovered");
|
throw std::runtime_error("No target IP defined nor Nanoleaf device discovered");
|
||||||
return false;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
//Get Nanoleaf device details and configuration
|
//Get Nanoleaf device details and configuration
|
||||||
|
Loading…
Reference in New Issue
Block a user