1
0
This commit is contained in:
Daniel Tartavel 2022-08-02 23:25:59 +02:00
parent d13529251b
commit d0489c7353
3 changed files with 4 additions and 8 deletions

View File

@ -230,7 +230,7 @@ function removeEvent(device $deviceObject, string $property , $value, int $metho
} }
} }
function searchEvent(device $deviceObject, string $property, $function, $value) function searchEvent(device $deviceObject, string $property, $value, $function=null)
{ {
global $events; global $events;
logger(DEBUG, sprintf(_("searching event for device %s, property %s and value %s"), $deviceObject->friendlyName, $property, bool2string($value)), __FILE__ . ":" . __LINE__); logger(DEBUG, sprintf(_("searching event for device %s, property %s and value %s"), $deviceObject->friendlyName, $property, bool2string($value)), __FILE__ . ":" . __LINE__);

View File

@ -42,7 +42,7 @@ class notificationFreemobile
$error = true; $error = true;
}else }else
{ {
logger(DEBUG, sprintf(_("Curl return: %s when sending notification"), $result), false, __FILE__ . ":" . __LINE__); logger(DEBUG, sprintf(_("Curl return: %s when sending notification"), curl_error($ch)), false, __FILE__ . ":" . __LINE__);
$this->curlErr = 0; $this->curlErr = 0;
} }
}else }else
@ -53,12 +53,9 @@ class notificationFreemobile
} }
$error = true; $error = true;
} }
//TODO managing curl errors //TODO managing curl errors
// close curl resource to free up system resources // close curl resource to free up system resources
curl_close($ch); curl_close($ch);
} }
return $error; return $error;
} }

View File

@ -44,7 +44,6 @@ class rdc_sdb_eclairage extends hook
{ {
if($deviceTarget->properties["state_l1"]["method"] == IDLE) if($deviceTarget->properties["state_l1"]["method"] == IDLE)
{ {
logger(DEBUG, _("lighting with method auto"), __FILE__ . ":" . __LINE__); logger(DEBUG, _("lighting with method auto"), __FILE__ . ":" . __LINE__);
//$deviceTarget->properties["state_l1"]["method"] = AUTO; //$deviceTarget->properties["state_l1"]["method"] = AUTO;
$this->send("ON", AUTO); $this->send("ON", AUTO);