From e00ff9d1fb8615dd61aef8314f3258ccb20db79f Mon Sep 17 00:00:00 2001 From: Philip Whitehouse Date: Tue, 29 Aug 2017 08:07:36 +0100 Subject: [PATCH] Rework check to fix NPE --- k9mail/src/main/java/com/fsck/k9/activity/Accounts.java | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/k9mail/src/main/java/com/fsck/k9/activity/Accounts.java b/k9mail/src/main/java/com/fsck/k9/activity/Accounts.java index e079d2274..32e02057d 100644 --- a/k9mail/src/main/java/com/fsck/k9/activity/Accounts.java +++ b/k9mail/src/main/java/com/fsck/k9/activity/Accounts.java @@ -905,11 +905,12 @@ public class Accounts extends K9ListActivity implements OnItemClickListener { mUseIncomingView.setChecked(mUseIncoming); } } else { + // Trigger afterTextChanged() being called + // Work around this bug: https://code.google.com/p/android/issues/detail?id=6360 if (configureIncomingServer) { - // Trigger afterTextChanged() being called - // Work around this bug: https://code.google.com/p/android/issues/detail?id=6360 mIncomingPasswordView.setText(mIncomingPasswordView.getText()); - } else { + } + if (configureOutgoingServer) { mOutgoingPasswordView.setText(mOutgoingPasswordView.getText()); } }