Skip to content

Commit

Permalink
increase get timeout
Browse files Browse the repository at this point in the history
  • Loading branch information
zoic21 authored Oct 29, 2024
1 parent 020acdc commit 53a593a
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion core/class/weather.class.php
Original file line number Diff line number Diff line change
Expand Up @@ -143,6 +143,7 @@ public static function calculDJU($methodeDJU, $temperatureID, $start, $end, $tem
}

public static function cron30($_eqLogic_id = null) {
sleep(rand(0,180));
if ($_eqLogic_id == null) {
$eqLogics = self::byType(__CLASS__, true);
} else {
Expand Down Expand Up @@ -1033,7 +1034,7 @@ public function updateWeatherData() {
$url .= '&lang=' . substr(config::byKey('language'), 0, 2);
$request_http = new com_http($url);
$request_http->setHeader(array('Autorization: ' . sha512(mb_strtolower(config::byKey('market::username')) . ':' . config::byKey('market::password'))));
$datas = json_decode($request_http->exec(10), true);
$datas = json_decode($request_http->exec(60,6), true);
log::add(__CLASS__, 'debug', $url . ' : ' . json_encode($datas));
if ($datas['state'] != 'ok') {
return;
Expand Down

0 comments on commit 53a593a

Please sign in to comment.