Unwrapping optionals crash
vincentneo opened this issue · 1 comments
vincentneo commented
MerchantKit/CommitPurchaseTask.swift:37: Fatal error: Unexpectedly found nil while implicitly unwrapping an Optional value
2022-05-16 00:51:10.066444+0800 ColourConvert[7610:247789] MerchantKit/CommitPurchaseTask.swift:37: Fatal error: Unexpectedly found nil while implicitly unwrapping an Optional value
Crashed happened at line 37 ( self.onCompletion(result)
).
Replicate:
- Start a
commitPurchaseTask
on merchant. - Sandbox payment made using an Apple ID without permissions to make in app purchases. (refer to screenshot)
- Press ok on step 2's popup.
- Observe crash.
While I could have done something wrong on my end, it looks more like a bug to me (probably some edge case situation that happens where account cannot buy IAPs). Feels worthy to report, even if it likely won't happen in production. Please advise if you believe it's a problem on my end.
Target Platform: macOS
Version of MerchantKit: master branch via SPM
vincentneo commented
Just realised it's my fault for not reading the README properly. Sorry!