Added remove_duplicate method