Fix bug on selection