diff --git a/LokiKit/LokiKit/ECKeyPair.h b/LokiKit/LokiKit/ECKeyPair.h index bdf4f53e8..c06c87c1d 100644 --- a/LokiKit/LokiKit/ECKeyPair.h +++ b/LokiKit/LokiKit/ECKeyPair.h @@ -2,6 +2,7 @@ @interface ECKeyPair (ECKeyPairExtension) +/// Based on `ECKeyPair.generateKeyPair()`. + (nonnull ECKeyPair *)generateKeyPairWithHexEncodedPrivateKey:(nonnull NSString *)hexEncodedPrivateKey; @end diff --git a/LokiKit/LokiKit/Mnemonic/Mnemonic.swift b/LokiKit/LokiKit/Mnemonic/Mnemonic.swift index b6a5973fa..40c4baa05 100644 --- a/LokiKit/LokiKit/Mnemonic/Mnemonic.swift +++ b/LokiKit/LokiKit/Mnemonic/Mnemonic.swift @@ -47,7 +47,7 @@ public enum Mnemonic { public enum DecodingError : LocalizedError { case generic, inputTooShort, missingLastWord, invalidWord, verificationFailed - public var errorDescription: String { + public var errorDescription: String? { switch self { case .generic: return NSLocalizedString("Something went wrong. Please check your mnemonic and try again.", comment: "") case .inputTooShort: return NSLocalizedString("Looks like you didn't enter enough words. Please check your mnemonic and try again.", comment: "") diff --git a/Signal/src/ViewControllers/Registration/OnboardingKeyPairViewController.swift b/Signal/src/ViewControllers/Registration/OnboardingKeyPairViewController.swift index 6f7f58286..96205e191 100644 --- a/Signal/src/ViewControllers/Registration/OnboardingKeyPairViewController.swift +++ b/Signal/src/ViewControllers/Registration/OnboardingKeyPairViewController.swift @@ -207,7 +207,6 @@ final class OnboardingKeyPairViewController : OnboardingBaseViewController { } catch let error { let error = error as? Mnemonic.DecodingError ?? Mnemonic.DecodingError.generic errorLabel.text = error.errorDescription - errorLabel.isHidden = false return } }