Better handle team/group deletion.