Handle request uri properly