finished implementing duplicateFilter