added handling for single candidate election