getDetail static method

Future<List<YKStorePayDetail>> getDetail(
  1. List<String> orderIds
)

Implementation

static Future<List<YKStorePayDetail>> getDetail(List<String> orderIds) async {
  Set<String> kIds = <String>{};

  for (String order in orderIds) {
    kIds.add(order);
  }

  try {
    final ProductDetailsResponse response = await InAppPurchase.instance.queryProductDetails(kIds);

    if (response.error == null) {
      var list = List<YKStorePayDetail>.from(response.productDetails.map((e) => YKStorePayDetail._make(e)));

      return list;
    }
  } catch (e) {}

  return [];
}