modified login.R and login_successful_stash.R