We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 4b119a9 commit 59d9294Copy full SHA for 59d9294
src/GeoIP.php
@@ -73,7 +73,7 @@ public function getIp()
73
{
74
if (! $this->ip) {
75
if ($this->random) {
76
- $this->ip = long2ip(rand(0, '4294967295'));
+ $this->ip = long2ip(mt_rand(0, 4294967295));
77
} else {
78
$this->ip = array_get($_SERVER, 'HTTP_CLIENT_IP', array_get($_SERVER, 'HTTP_X_FORWARDED_FOR', array_get($_SERVER, 'HTTP_X_FORWARDED', array_get($_SERVER, 'HTTP_FORWARDED_FOR', array_get($_SERVER, 'HTTP_FORWARDED', array_get($_SERVER, 'REMOTE_ADDR', '127.0.0.1'))))));
79
}
0 commit comments