fix check for uniqueness, "and False or True" will always return True