Removal of entites prevents attempts to remove detached objects.