Skip to content

Commit

Permalink
Resolve #99 & publish 2.0.0+7
Browse files Browse the repository at this point in the history
  • Loading branch information
hyochan committed Sep 27, 2019
1 parent dae8578 commit b5a1093
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 7 deletions.
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
## 2.0.0+7
* Resolve [#99](https://github.com/dooboolab/flutter_inapp_purchase/issues/99).
## 2.0.0+6
* Send `purchase-error` with purchases returns null.
## 2.0.0+5
Expand Down
9 changes: 3 additions & 6 deletions lib/flutter_inapp_purchase.dart
Original file line number Diff line number Diff line change
Expand Up @@ -414,17 +414,14 @@ class FlutterInappPurchase {
/// Call this after finalizing server-side validation of the reciept.
///
/// No effect on `Android`, who does not allow this type of functionality.
Future<PurchaseResult> finishTransactionIOS(String purchaseToken) async {
Future<String> finishTransactionIOS(String purchaseToken) async {
if (_platform.isAndroid) {
return PurchaseResult(
debugMessage: 'no ops in android',
);
return 'no ops in android';
} else if (_platform.isIOS) {
String result = await _channel.invokeMethod('finishTransaction', <String, dynamic>{
'transactionIdentifier': purchaseToken,
});
PurchaseResult decoded = json.decode(result.toString());
return decoded;
return result;
}
throw PlatformException(
code: _platform.operatingSystem, message: "platform not supported");
Expand Down
2 changes: 1 addition & 1 deletion pubspec.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
name: flutter_inapp_purchase
description: In App Purchase plugin for flutter. This project has been forked by react-native-iap and we are willing to share same experience with that on react-native.
version: 2.0.0+6
version: 2.0.0+7
author: dooboolab<dooboolab@gmail.com>
homepage: https://github.com/dooboolab/flutter_inapp_purchase/blob/master/pubspec.yaml
environment:
Expand Down

0 comments on commit b5a1093

Please sign in to comment.