• This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn more.

XF 2.0 Ip ControllerPlugin

#1
How can I add a condition to users with IDs 1 and 2. This section of code does not work
PHP:
$user = $this->em()->find('XF:User', $this->filter('user_id', 'uint'));
if($user['user_id'] == 1)
{
    return $this->error(\XF::phrase('no_ip_information_available'));
}