Changed way of managing sessions