ensure argument to check_selected is an integer