Better duplicate handling