updated remove button handling.