Torann / laravel-geoip

Determine the geographical location of website visitors based on their IP addresses.
http://lyften.com/projects/laravel-geoip
BSD 2-Clause "Simplified" License
2.1k stars 373 forks source link

500 Internal Server Error #146

Open hongyukeji opened 5 years ago

hongyukeji commented 5 years ago

src/GeoIP.php 241 row add code

// Fixed bug #75794 (getenv() crashes on Windows 7.2.1 when second parameter is false).
if (strtoupper(substr(PHP_OS, 0, 3)) === 'WIN'
    && version_compare(PHP_VERSION, '7.1.13', '>=')
    && version_compare(PHP_VERSION, '7.2.10', '<=')) {
    array_splice($remotes_keys, array_search('REMOTE_ADDR', $remotes_keys), 1);
}