removes potential duplicates