Improved session example to remove flag properly.