Can re-enable a default disabled stream with conf.php

This commit is contained in:
Laurent Destailleur
2023-07-29 17:31:27 +02:00
parent 69c7579610
commit e12bfb3e3c
2 changed files with 15 additions and 13 deletions

View File

@@ -56,11 +56,13 @@ class DolGeoIP
if ($type == 'country') {
// geoip may have been already included with PEAR
if ($geoipversion == '2' || ($geoipversion != 'php' && !function_exists('geoip_country_code_by_name'))) {
stream_wrapper_restore('phar');
require_once DOL_DOCUMENT_ROOT.'/includes/geoip2/geoip2.phar';
}
} elseif ($type == 'city') {
// geoip may have been already included with PEAR
if ($geoipversion == '2' || ($geoipversion != 'php' && !function_exists('geoip_country_code_by_name'))) {
stream_wrapper_restore('phar');
require_once DOL_DOCUMENT_ROOT.'/includes/geoip2/geoip2.phar';
}
} else {