redid the request handler to iterate over the entire uri to find the deepest router.