Reset an arduino to factory

If code was programmed using an Atmel ICE (or any ISP programmer), that would have erased the bootloader, so that you need to do a "burn bootloader" (or equivalent) (using an external programmer) before you can simply "upload" sketches again.