When updating key, destroy the old one before creating the new one