public function matches($request, $queries = [])
    {
        $this->setQueries($queries);

        if (! $request && $this->isHomePath()) {
            return true;
        }

        if ($matches = preg_match("@^{$this->getPathMock($queries)}$@", $request)) {
            if ($this->rulesNotPassed()) {
                return false;
            }
        }

        return (bool) $matches;
    }