Add session checking back in. Related to #128