fix bug for close remove