modify val when session has not been created.