Session shutdown working