saving session, improvements