code merge from sample app with login session