Merge pull request #19167 from atm-maxime/fix_currency_sync
Fix #18922 : multicurrency sync in http with good currencylayer url
This commit is contained in:
commit
66a732c005
@ -643,13 +643,12 @@ class MultiCurrency extends CommonObject
|
||||
|
||||
include_once DOL_DOCUMENT_ROOT.'/core/lib/geturl.lib.php';
|
||||
|
||||
$urlendpoint = 'http://apilayer.net/api/live?access_key='.$key;
|
||||
//$urlendpoint.='&format=1';
|
||||
$urlendpoint .= (empty($conf->global->MULTICURRENCY_APP_SOURCE) ? '' : '&source='.$conf->global->MULTICURRENCY_APP_SOURCE);
|
||||
$urlendpoint = 'http://api.currencylayer.com/live?access_key='.$key;
|
||||
$urlendpoint .= '&source=' . (empty($conf->global->MULTICURRENCY_APP_SOURCE) ? 'USD' : $conf->global->MULTICURRENCY_APP_SOURCE);
|
||||
|
||||
dol_syslog("Call url endpoint ".$urlendpoint);
|
||||
|
||||
$resget = getURLContent($urlendpoint, 'GET', '', 1, array(), array('http', 'https'), 1);
|
||||
$resget = getURLContent($urlendpoint);
|
||||
|
||||
if ($resget['content']) {
|
||||
$response = $resget['content'];
|
||||
|
||||
Loading…
Reference in New Issue
Block a user