fixed remove element bug