Changed the Login activity to  a startActivityForResult.