fix: api und disablle

This commit is contained in:
Sebastian 2024-05-22 18:15:35 +02:00
parent f38236f721
commit 640a7544d7
2 changed files with 6 additions and 10 deletions

View File

@ -694,17 +694,13 @@ sub ErrorHandling {
}
elsif ( $decode_json->{errors}[0]{code} eq "ratelimit.exceeded" ) {
Log3 $dname, 5,
"GardenaSmartBridge ($dname) - RequestERROR: error ratelimit.exceeded";
readingsBulkUpdate( $dhash, "lastRequestState", "too many requests", 1 );
readingsBulkUpdate( $dhash, "state", "inactive", 1 );
Log3 $name, 5,
"GardenaSmartBridge ($name) - RequestERROR: error ratelimit.exceeded";
readingsBulkUpdate( $hash, "lastRequestState", "too many requests", 1 );
readingsBulkUpdate( $hash, "state", "inactive", 1 );
# remove all timer and disable bridge
readingsBulkUpdate( $dhash, "disable", "1", 1 );
# AttrVal( $name, 'disable', '1');
RemoveInternalTimer( $dhash, "FHEM::GardenaSmartBridge::getDevices" );
RemoveInternalTimer( $dhash, "FHEM::GardenaSmartBridge::getToken" );
RemoveInternalTimer( $hash );
return; # post request max.
}
else {

View File

@ -1,2 +1,2 @@
UPD 2024-05-21_22:04:23 51083 FHEM/73_GardenaSmartBridge.pm
UPD 2024-05-22_18:13:20 50855 FHEM/73_GardenaSmartBridge.pm
UPD 2024-05-21_09:01:54 127762 FHEM/74_GardenaSmartDevice.pm