protected function validateIn($field, $value, $params)
    {
        $isAssoc = \array_values($params[0]) !== $params[0];
        if ($isAssoc) {
            $params[0] = \array_keys($params[0]);
        }

        $strict = false;
        if (isset($params[1])) {
            $strict = $params[1];
        }

        return \in_array($value, $params[0], $strict);
    }