applied some fixes to the sessions