I am implementing an in app purchase and I am sending the request to apple store through
- (void) requestProductData
{
SKProductsRequest *request= [[SKProductsR
I faced the same problem, but in my case the cause was that I was using Automatic Reference Counting and I forgot to retain the request.
My code was like:
- (void) requestProductData
{
SKProductsRequest *request= [[SKProductsRequest alloc] initWithProductIdentifiers:[NSSet setWithObject:ProductIdentifier]];
request.delegate = self;
[request start];
}
But delegate's productsRequest:didReceiveResponse: never got called.
A fix would be:
@property (strong, nonatomic) SKProductsRequest *request;
- (void) requestProductData
{
self.request= [[SKProductsRequest alloc] initWithProductIdentifiers:[NSSet setWithObject:ProductIdentifier]];
self.request.delegate = self;
[self.request start];
// you can nil request property in request:didFailWithError: and requestDidFinish:
}