Modifying uri to connect