Refactor URL input source stuff.