31_HUEDevice.pm: fixed warnung for devices with no commands

git-svn-id: https://svn.fhem.de/fhem/trunk/fhem@21837 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
justme-1968 2020-05-02 08:59:46 +00:00
parent 0a554bfef2
commit c66c0b1ba2

View File

@ -1253,10 +1253,13 @@ HUEDevice_Get($@)
$list = ' devStateIcon:noArg' if( $subtype eq 'blind' ); $list = ' devStateIcon:noArg' if( $subtype eq 'blind' );
} }
if( $hash->{IODev} && $hash->{IODev}{helper}{apiversion} && $hash->{IODev}{helper}{apiversion} >= (1<<16) + (26<<8) ) { if( !$hash->{helper}->{devtype}
&& $hash->{IODev} && $hash->{IODev}{helper}{apiversion} && $hash->{IODev}{helper}{apiversion} >= (1<<16) + (26<<8) ) {
$list .= " startup:noArg"; $list .= " startup:noArg";
} }
return "Unknown argument $cmd" if( !$list );
return "Unknown argument $cmd, choose one of $list"; return "Unknown argument $cmd, choose one of $list";
} }