prevent entity.locations from containing duplicates