From 53f851afc5edaa0975ada702be1898b902deb132 Mon Sep 17 00:00:00 2001 From: Stephan Diederich Date: Wed, 11 Sep 2013 16:17:13 +0200 Subject: [PATCH] always provide an error to the viewcontroller --- Classes/BITAuthenticator.m | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/Classes/BITAuthenticator.m b/Classes/BITAuthenticator.m index 3d25bf1589..a11f9af3f3 100644 --- a/Classes/BITAuthenticator.m +++ b/Classes/BITAuthenticator.m @@ -345,6 +345,13 @@ static NSString* const kBITAuthenticatorDidSkipOptionalLogin = @"BITAuthenticato NSLocalizedDescriptionKey : BITHockeyLocalizedString(@"Not authorized"), NSUnderlyingErrorKey : authParseError }]; + } else { + error = [NSError errorWithDomain:kBITAuthenticatorErrorDomain + code:BITAuthenticatorErrorUnknown + userInfo:@{ + NSLocalizedDescriptionKey : BITHockeyLocalizedString(@"Failed to authenticate. Please try again later."), + NSUnderlyingErrorKey : authParseError + }]; } completion(NO, error); } else {