Merge "Check for account before launching welcome screen."

This commit is contained in:
Mindy Pereira 2011-11-28 11:35:07 -08:00 committed by Android (Google) Code Review
commit ac96f64081

View File

@ -1778,7 +1778,7 @@ public class MessageCompose extends Activity implements OnClickListener, OnFocus
return; return;
} }
if (isOpenedFromWidget() || !systemKey) { if ((isOpenedFromWidget() || !systemKey) && (mAccount != null)) {
// Otherwise, need to open the main screen for the appropriate account. // Otherwise, need to open the main screen for the appropriate account.
// Note that mAccount should always be set by the time the action bar is set up. // Note that mAccount should always be set by the time the action bar is set up.
startActivity(Welcome.createOpenAccountInboxIntent(this, mAccount.mId)); startActivity(Welcome.createOpenAccountInboxIntent(this, mAccount.mId));