bug 2 fix then do next session function