forked from Wavyzz/dolibarr
QUAL All $conf->global->module->enabled are replaced with isModEnabled()
This commit is contained in:
@@ -4520,7 +4520,7 @@ function dolGetCountryCodeFromIp($ip)
|
||||
|
||||
$countrycode = '';
|
||||
|
||||
if (!empty($conf->geoipmaxmind->enabled)) {
|
||||
if (isModEnabled('geoipmaxmind')) {
|
||||
$datafile = getDolGlobalString('GEOIPMAXMIND_COUNTRY_DATAFILE');
|
||||
//$ip='24.24.24.24';
|
||||
//$datafile='/usr/share/GeoIP/GeoIP.dat'; Note that this must be downloaded datafile (not same than datafile provided with ubuntu packages)
|
||||
@@ -4546,7 +4546,7 @@ function dol_user_country()
|
||||
|
||||
//$ret=$user->xxx;
|
||||
$ret = '';
|
||||
if (!empty($conf->geoipmaxmind->enabled)) {
|
||||
if (isModEnabled('geoipmaxmind')) {
|
||||
$ip = getUserRemoteIP();
|
||||
$datafile = getDolGlobalString('GEOIPMAXMIND_COUNTRY_DATAFILE');
|
||||
//$ip='24.24.24.24';
|
||||
|
||||
Reference in New Issue
Block a user