public function dispatch($path, RouteRequest $request = null)
    {
        if ($route = $this->match($path)) {
            // When the callback is an integer, it's refereing to a submux object.
            if (is_integer($route[2])) {
                $submux = $this->submux[$route[2]];
                $options = $route[3];

                // sub-path and call submux to dispatch
                // for pcre pattern?
                if ($route[0]) {

                    $matchedString = $route[3]['vars'][0];

                    return $submux->dispatch(substr($path, strlen($matchedString)));

                } else {
                    $s = substr($path, strlen($route[1]));

                    return $submux->dispatch(
                        substr($path, strlen($route[1])) ?: ''
                    );
                }
            }

            return $route;
        }
    }