fix selection logic