Improve version selection.