added the new URI code to switch