Minor clean up.
Cleaned up of getting session preferences.