Skip to content
This repository has been archived by the owner on Mar 4, 2020. It is now read-only.

Commit

Permalink
If receipt is missing, iap was never initiated. Error removed
Browse files Browse the repository at this point in the history
  • Loading branch information
MugunthKumar committed Feb 19, 2015
1 parent c1b34eb commit 67619ed
Showing 1 changed file with 2 additions and 5 deletions.
7 changes: 2 additions & 5 deletions MKStoreKit.m
Expand Up @@ -108,8 +108,7 @@ + (void)initialize {
@(21005) : @"The receipt server is not currently available.",
@(21006) : @"This receipt is valid but the subscription has expired.",
@(21007) : @"This receipt is from the test environment.",
@(21008) : @"This receipt is from the production environment.",
@(21009) : @"The receipt does not exist."};
@(21008) : @"This receipt is from the production environment."};
}

#pragma mark -
Expand Down Expand Up @@ -293,9 +292,7 @@ - (void)startValidatingAppStoreReceiptWithCompletionHandler:(void (^)(NSArray *r
BOOL isPresent = [receiptURL checkResourceIsReachableAndReturnError:&receiptError];
if (!isPresent) {
// No receipt - In App Purchase was never initiated
NSError *error = [NSError errorWithDomain:@"com.mugunthkumar.mkstorekit" code:21009
userInfo:@{NSLocalizedDescriptionKey : @"The reciept does not exist."}];
completionHandler(nil, error);
completionHandler(nil, nil);
return;
}

Expand Down

0 comments on commit 67619ed

Please sign in to comment.