Correcting session bug