It would be easier /nicer to prevent duplicates in the first place...