style fixes, fixed session request token, refactored ternaries