- (BOOL)fetcherShouldBeginFetching:(GTMHTTPFetcher *)fetcher
NSString *host = [[[fetcher mutableRequest] URL] host];
if ([host length] == 0) {
#if DEBUG
NSAssert1(0, @"%@ lacks host", fetcher);
#endif
return YES;
}
According to my debug information host is nil.
Just changing authentication persistence to keychain everything works like a charm.
What is wrong with my implementation of NSCoding?
The URL is nil, I also noticed that the userEmail for the authToken is nil.It seems that I'm doing something wrong in the store/restore....
Class signInClass = [GTMOAuth2WindowController signInClass];
NSURL *tokenURL = [signInClass googleTokenURL];
NSString *redirectURI = [signInClass nativeClientRedirectURI];
GTMOAuth2Authentication *theAuthToken;
theAuthToken = [GTMOAuth2Authentication authenticationWithServiceProvider:kGTMOAuth2ServiceProviderGoogle
tokenURL:tokenURL
redirectURI:redirectURI
clientID:myClientID
clientSecret:myClientSecret];