This is incorrect. URL's are allowed to have `:`s in them, and this will break.