I’m getting an error:
Incompatible block pointer types sending ‘void (^)(NSString
*_strong)’ to parameter of type ‘void (^)(NSString *_strong, NSData *__strong)’
When I’m implementing MKStoreKit 4.3 in my app on the line of onComplete:
-(IBAction)purchaseFull {
[[MKStoreManager sharedManager] buyFeature:@"productID"
onComplete:^(NSString* purchasedFeature)
{
NSLog(@"Purchased: %@", purchasedFeature);
//purchaseBtn.hidden = YES;
}
onCancelled:^
{
NSLog(@"User Cancelled Transaction");
}];
}
The API you are trying to use has a method like this:
but, for the
completionBlockparameter, you’re passingwhich means you are missing the second (
NSData*) parameter.Change your code to something like this: