Some cleanup in restore.