Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Renamed purchaseToken -> purchaseTokenAndroid #1130

Merged
merged 5 commits into from
Sep 26, 2020
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -369,15 +369,15 @@ export const requestPurchase = (
* @param {string} sku The product's sku/ID
* @param {boolean} [andDangerouslyFinishTransactionAutomaticallyIOS] You should set this to false and call finishTransaction manually when you have delivered the purchased goods to the user. It defaults to true to provide backwards compatibility. Will default to false in version 4.0.0.
* @param {string} [oldSkuAndroid] SKU that the user is upgrading or downgrading from.
* @param {string} [purchaseToken] purchaseToken that the user is upgrading or downgrading from (Android).
* @param {string} [purchaseTokenAndroid] purchaseToken that the user is upgrading or downgrading from (Android).
* @param {ProrationModesAndroid} [prorationModeAndroid] UNKNOWN_SUBSCRIPTION_UPGRADE_DOWNGRADE_POLICY, IMMEDIATE_WITH_TIME_PRORATION, IMMEDIATE_AND_CHARGE_PRORATED_PRICE, IMMEDIATE_WITHOUT_PRORATION, DEFERRED
* @returns {Promise<void>}
*/
export const requestSubscription = (
sku: string,
andDangerouslyFinishTransactionAutomaticallyIOS?: boolean,
oldSkuAndroid?: string,
purchaseToken?: string,
purchaseTokenAndroid?: string,
prorationModeAndroid?: ProrationModesAndroid,
): Promise<SubscriptionPurchase> =>
Platform.select({
Expand All @@ -404,7 +404,7 @@ export const requestSubscription = (
ANDROID_ITEM_TYPE_SUBSCRIPTION,
sku,
oldSkuAndroid,
purchaseToken,
purchaseTokenAndroid,
prorationModeAndroid,
);
},
Expand Down