mirror of
https://github.com/fhem/fhem-mirror.git
synced 2025-03-03 23:06:37 +00:00
30_HUEBridge.pm: changed not paired handling
git-svn-id: https://svn.fhem.de/fhem/trunk@11347 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
parent
95421407a6
commit
534540078f
@ -281,7 +281,7 @@ HUEBridge_Set($@)
|
||||
my ($arg, @params) = @args;
|
||||
|
||||
return "$name: not paired" if( $hash->{STATE} =~ m/^link/ );
|
||||
return "$name: not connected" if( $hash->{STATE} ne 'Connected' );
|
||||
#return "$name: not connected" if( $hash->{STATE} ne 'Connected' );
|
||||
|
||||
# usage check
|
||||
if($cmd eq 'statusRequest') {
|
||||
@ -490,7 +490,7 @@ HUEBridge_Get($@)
|
||||
my ($arg, @params) = @args;
|
||||
|
||||
return "$name: not paired" if( $hash->{STATE} =~ m/^link/ );
|
||||
return "$name: not connected" if( $hash->{STATE} ne 'Connected' );
|
||||
#return "$name: not connected" if( $hash->{STATE} ne 'Connected' );
|
||||
return "$name: get needs at least one parameter" if( !defined($cmd) );
|
||||
|
||||
# usage check
|
||||
@ -498,7 +498,6 @@ HUEBridge_Get($@)
|
||||
|| $cmd eq 'lights') {
|
||||
my $result = HUEBridge_Call($hash, undef, 'lights', undef);
|
||||
return $result->{error}{description} if( $result->{error} );
|
||||
Log 1, Dumper $result;
|
||||
my $ret = "";
|
||||
foreach my $key ( sort {$a<=>$b} keys %{$result} ) {
|
||||
my $code = $name ."-". $key;
|
||||
|
Loading…
x
Reference in New Issue
Block a user