protected function requestRouteMatchesPrefix($prefix)
    {
        $prefixSegments = $this->splitPrefixSegments($prefix);
        $request = request();

        foreach ($prefixSegments as $index => $segment) {
            if (strtolower($request->segment($index + 1)) !== $segment) {
                return false;
            }
        }

        return true;
    }