- (NSString *)getAuthorizationHeader{
iKMAppDelegate *delegate = (iKMAppDelegate *)[UIApplication sharedApplication].delegate;
NSString *header = [NSString stringWithFormat:@"Bearer %@", delegate.appDataObject.oauth2AcessToken];
return header;
}
this method will got a warning in XCode9
[UIApplication delegate] must be called from main thread only
and i dont think a dispatch in main queue will be working for my function . so how to fix this warning well?