Allow session to be set in session helper
Merge pull request #6849 from JosephSilber/session-helper

[5.0] Add session helper functionality