From eecc823d8512ed156dc398924dd9f46b10c17b41 Mon Sep 17 00:00:00 2001 From: Matthew Chen Date: Fri, 25 May 2018 14:30:54 -0400 Subject: [PATCH] Fix invite flow. --- Signal/src/ViewControllers/InviteFlow.swift | 4 +++- Signal/translations/en.lproj/Localizable.strings | 3 +++ 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/Signal/src/ViewControllers/InviteFlow.swift b/Signal/src/ViewControllers/InviteFlow.swift index c788b2f6b..e184adf76 100644 --- a/Signal/src/ViewControllers/InviteFlow.swift +++ b/Signal/src/ViewControllers/InviteFlow.swift @@ -129,7 +129,9 @@ class InviteFlow: NSObject, MFMessageComposeViewControllerDelegate, MFMailCompos func contactsPicker(_: ContactsPicker, contactFetchDidFail error: NSError) { Logger.error("\(self.logTag) in \(#function) with error: \(error)") - self.presentingViewController.dismiss(animated: true) + self.presentingViewController.dismiss(animated: true) { + OWSAlerts.showErrorAlert(message: NSLocalizedString("ERROR_COULD_NOT_FETCH_CONTACTS", comment: "Error indicating that the phone's contacts could not be retrieved.")) + } } func contactsPickerDidCancel(_: ContactsPicker) { diff --git a/Signal/translations/en.lproj/Localizable.strings b/Signal/translations/en.lproj/Localizable.strings index 32f3b84e7..9b6f3ecf3 100644 --- a/Signal/translations/en.lproj/Localizable.strings +++ b/Signal/translations/en.lproj/Localizable.strings @@ -797,6 +797,9 @@ /* Call setup status label */ "END_CALL_UNCATEGORIZED_FAILURE" = "Call Failed."; +/* Error indicating that the phone's contacts could not be retrieved. */ +"ERROR_COULD_NOT_FETCH_CONTACTS" = "Could not access contacts."; + /* Generic notice when message failed to send. */ "ERROR_DESCRIPTION_CLIENT_SENDING_FAILURE" = "Failed to send message.";