protected function validateRequired($field, $value, array $params = [], array $fields = [])
    {
        if (isset($params[0]) && (bool) $params[0]) {
            $find = $this->getPart($fields, \explode('.', $field), true);

            return $find[1];
        }

        if (null === $value) {
            return false;
        }

        if (\is_string($value) && \trim($value) === '') {
            return false;
        }

        return true;
    }