Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 6 additions & 4 deletions Source/AppAuthCore/OIDAuthState.m
Original file line number Diff line number Diff line change
Expand Up @@ -377,10 +377,12 @@ - (void)updateWithTokenResponse:(nullable OIDTokenResponse *)tokenResponse
// Calling updateWithTokenResponse while in an error state probably means the developer obtained
// a new token and did the exchange without also calling updateWithAuthorizationResponse.
// Attempts to handle gracefully, but warns the developer that this is unexpected.
NSLog(@"OIDAuthState:updateWithTokenResponse should not be called in an error state [%@] call"
"updateWithAuthorizationResponse with the result of the fresh authorization response"
"first",
_authorizationError);
NSLog(@"OIDAuthState:updateWithTokenResponse should not be called in an error state."
"Enable AppAuthRequestTrace to see the details.");
AppAuthRequestTrace(@"OIDAuthState:updateWithTokenResponse should not be called in an error state"
"[%@] call updateWithAuthorizationResponse with the result of the fresh"
"authorization response first",
_authorizationError);

_authorizationError = nil;
}
Expand Down
4 changes: 3 additions & 1 deletion Source/AppAuthCore/OIDIDToken.m
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@
static NSString *const kNonceKey = @"nonce";

#import "OIDFieldMapping.h"
#import "OIDDefines.h"

@implementation OIDIDToken

Expand Down Expand Up @@ -117,7 +118,8 @@ + (NSDictionary *)parseJWTSection:(NSString *)sectionString {
NSError *error;
id object = [NSJSONSerialization JSONObjectWithData:decodedData options:0 error:&error];
if (error) {
NSLog(@"Error %@ parsing token payload %@", error, sectionString);
NSLog(@"Error parsing token payload. Enable AppAuthRequestTrace to see the details.");
AppAuthRequestTrace(@"Error %@ parsing token payload %@", error, sectionString);
}
if ([object isKindOfClass:[NSDictionary class]]) {
return (NSDictionary *)object;
Expand Down