aboutsummaryrefslogtreecommitdiffstats
path: root/OpenKeychain/src/main/java/org/sufficientlysecure/keychain/provider/ProviderHelper.java
diff options
context:
space:
mode:
Diffstat (limited to 'OpenKeychain/src/main/java/org/sufficientlysecure/keychain/provider/ProviderHelper.java')
-rw-r--r--OpenKeychain/src/main/java/org/sufficientlysecure/keychain/provider/ProviderHelper.java12
1 files changed, 6 insertions, 6 deletions
diff --git a/OpenKeychain/src/main/java/org/sufficientlysecure/keychain/provider/ProviderHelper.java b/OpenKeychain/src/main/java/org/sufficientlysecure/keychain/provider/ProviderHelper.java
index 33e9a4345..a4ee7fc36 100644
--- a/OpenKeychain/src/main/java/org/sufficientlysecure/keychain/provider/ProviderHelper.java
+++ b/OpenKeychain/src/main/java/org/sufficientlysecure/keychain/provider/ProviderHelper.java
@@ -648,10 +648,6 @@ public class ProviderHelper {
UserPacketItem item = uids.get(userIdRank);
operations.add(buildUserIdOperations(masterKeyId, item, userIdRank));
- if (item.selfCert == null) {
- throw new AssertionError("User ids MUST be self-certified at this point!!");
- }
-
if (item.selfRevocation != null) {
operations.add(buildCertOperations(masterKeyId, userIdRank, item.selfRevocation,
Certs.VERIFIED_SELF));
@@ -659,6 +655,10 @@ public class ProviderHelper {
continue;
}
+ if (item.selfCert == null) {
+ throw new AssertionError("User ids MUST be self-certified at this point!!");
+ }
+
operations.add(buildCertOperations(masterKeyId, userIdRank, item.selfCert,
selfCertsAreTrusted ? Certs.VERIFIED_SECRET : Certs.VERIFIED_SELF));
@@ -782,7 +782,7 @@ public class ProviderHelper {
// first, mark all keys as not available
ContentValues values = new ContentValues();
- values.put(Keys.HAS_SECRET, SecretKeyType.UNAVAILABLE.getNum());
+ values.put(Keys.HAS_SECRET, SecretKeyType.GNU_DUMMY.getNum());
mContentResolver.update(uri, values, null, null);
// then, mark exactly the keys we have available
@@ -831,7 +831,7 @@ public class ProviderHelper {
mIndent -= 1;
// this implicitly leaves all keys which were not in the secret key ring
- // with has_secret = 0
+ // with has_secret = 1
}
log(LogType.MSG_IS_SUCCESS);