fixed bug on selection