【发布时间】:2020-12-20 23:22:47
【问题描述】:
我正在使用 in_app_purchases Flutter 包来处理我在 android 和 ios 上的应用内购买需求。我只使用消耗性 IAP。但是我的购买流没有触发。只有 queryPastPurchases 方法返回消耗品列表。所以我对插件有点困惑。一旦应用程序在 main 方法中启动,我也开始收听购买流。但是我没有收到购买流中的购买更新。
in_app_purchase 中的这个声明似乎有点模棱两可,它说尝试完成待处理的购买可能会导致错误。但是提到在待处理状态下重试购买完成
Completing a [PurchaseStatus.pending] purchase will cause an exception.
For convenience, [PurchaseDetails.pendingCompletePurchase] indicates if a
purchase is pending for completion.
The method returns a [BillingResultWrapper] to indicate a detailed status
of the complete process.
If the result contains [BillingResponse.error] or
[BillingResponse.serviceUnavailable], the developer should try
to complete the purchase via this method again, or retry the
[completePurchase] it at a later time.
If the result indicates other errors, there might be some issue with
the app's code. The developer is responsible to fix the issue.
【问题讨论】:
标签: android ios flutter dart in-app-purchase