protected function hasRule(string $name, string $field): bool
    {
        foreach ($this->_validations as $validation) {
            if ($validation['rule'] === $name && \in_array($field, $validation['fields'], true)) {
                return true;
            }
        }

        return false;
    }