fixed bugs for session making