Fixed a bug when checking for clones.