Add automatic restoring of mappings