don't cache passphrase twice

This commit is contained in:
Ash Hughes 2013-03-14 12:58:09 +00:00
parent cf42bcd039
commit 911719bdb6

View file

@ -231,7 +231,7 @@ public class PassphraseDialogFragment extends DialogFragment implements OnEditor
// cache the new passphrase
Log.d(Constants.TAG, "Everything okay! Caching entered passphrase");
PassphraseCacheService.addCachedPassphrase(activity, keyId, passPhrase);
if (keyOK == false) {
if (keyOK == false && clickSecretKey.getKeyID() != keyId) {
PassphraseCacheService.addCachedPassphrase(activity, clickSecretKey.getKeyID(), passPhrase);
}