mirror of
https://github.com/Mibew/mibew.git
synced 2025-06-01 15:02:34 +03:00
Add missing user IP fix
This commit is contained in:
parent
aa3ae32a94
commit
a599fafcfc
@ -438,8 +438,8 @@ class UsersProcessor extends ClientSideProcessor implements AuthenticationManage
|
||||
$user_agent = get_user_agent_version($details['user_agent']);
|
||||
|
||||
// Get user ip
|
||||
if (preg_match("/(\\d+\\.\\d+\\.\\d+\\.\\d+)/", $details['remote_host'], $matches) != 0) {
|
||||
$user_ip = $matches[1];
|
||||
if (preg_match_all("/(\\d+\\.\\d+\\.\\d+\\.\\d+)/", $details['remote_host'], $matches) != 0) {
|
||||
$user_ip = end($matches[1]);
|
||||
} else {
|
||||
$user_ip = false;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user