Session cookie bug fix