Adding auto-save to session