resolving duplicates