Improve deleteSelected