Minor - format code + simplifying code.
Minor - format code + adding intval.
Prevent multiple login option see BT#8796
Using Session::read()