mirror of
https://github.com/SideStore/SideStore.git
synced 2026-02-18 19:23:43 +01:00
[AltKit] Includes underlying error in error response
This commit is contained in:
@@ -39,13 +39,19 @@ NSErrorUserInfoKey const ALTProvisioningProfileBundleIDErrorKey = @"bundleIdenti
|
||||
{
|
||||
case ALTServerErrorUnderlyingError:
|
||||
{
|
||||
NSString *underlyingErrorCode = self.userInfo[ALTUnderlyingErrorCodeErrorKey];
|
||||
if (underlyingErrorCode == nil)
|
||||
NSError *underlyingError = self.userInfo[NSUnderlyingErrorKey];
|
||||
if (underlyingError.localizedFailureReason != nil)
|
||||
{
|
||||
return NSLocalizedString(@"An unknown error occured.", @"");
|
||||
return underlyingError.localizedFailureReason;
|
||||
}
|
||||
|
||||
NSString *underlyingErrorCode = self.userInfo[ALTUnderlyingErrorCodeErrorKey];
|
||||
if (underlyingErrorCode != nil)
|
||||
{
|
||||
return [NSString stringWithFormat:NSLocalizedString(@"Error code: %@", @""), underlyingErrorCode];
|
||||
}
|
||||
|
||||
return [NSString stringWithFormat:NSLocalizedString(@"Error code: %@", @""), underlyingErrorCode];
|
||||
return NSLocalizedString(@"An internal error occured.", @"");
|
||||
}
|
||||
|
||||
case ALTServerErrorUnknown:
|
||||
|
||||
Reference in New Issue
Block a user