Skip to content

Commit 16eab57

Browse files
Billing library bumped to 1.1.0, removed warnings about alpha dependencies
1 parent 46c3da7 commit 16eab57

6 files changed

Lines changed: 3 additions & 23 deletions

File tree

packages/cli/src/lib/cmds/init.ts

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -139,10 +139,6 @@ async function confirmTwaConfig(twaManifest: TwaManifest, prompt: Prompt): Promi
139139

140140
const playBillingEnabled = await prompt.promptConfirm(messages.promptPlayBilling, false);
141141
if (playBillingEnabled) {
142-
twaManifest.alphaDependencies = {
143-
enabled: true,
144-
};
145-
146142
twaManifest.features = {
147143
...twaManifest.features,
148144
playBilling: {

packages/cli/src/lib/cmds/shared.ts

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -128,11 +128,6 @@ export async function updateProject(
128128
prompt.printMessage(messages.errorPlayBillingEnableNotifications);
129129
return false;
130130
}
131-
// Check that if Play Billing is enabled, alphaDependencies must also be enabled.
132-
if (features.playBilling?.enabled && !twaManifest.alphaDependencies.enabled) {
133-
prompt.printMessage(messages.errorPlayBillingAlphaDependencies);
134-
return false;
135-
}
136131

137132
// Check that the iconUrl exists.
138133
if (!twaManifest.iconUrl) {

packages/cli/src/lib/strings.ts

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,6 @@ type Messages = {
2424
errorFailedToRunQualityCriteria: string;
2525
errorIconUrlMustExist: (manifest: string) => string;
2626
errorPlayBillingEnableNotifications: string;
27-
errorPlayBillingAlphaDependencies: string;
2827
errorMaxLength: (maxLength: number, actualLength: number) => string;
2928
errorMinLength: (minLength: number, actualLength: number) => string;
3029
errorMissingManifestParameter: string;
@@ -149,8 +148,6 @@ export const enUS: Messages = {
149148
yellow('\nFailed to run the PWA Quality Criteria checks. Skipping.'),
150149
errorPlayBillingEnableNotifications: red(`Play Billing requires ${cyan('enableNotifications')} ` +
151150
`to be ${cyan('true')}.`),
152-
errorPlayBillingAlphaDependencies: red(`Play Billing requires ${cyan('alphaDependencies')} ` +
153-
'to be enabled.'),
154151
errorMaxLength: (maxLength, actualLength): string => {
155152
return `Maximum length is ${maxLength} but input is ${actualLength}.`;
156153
},
@@ -370,7 +367,7 @@ the PWA:
370367
promptMaskableIconUrl: 'Maskable icon URL:',
371368
promptMonochromeIconUrl: 'Monochrome icon URL:',
372369
promptShortcuts: 'Include app shortcuts?',
373-
promptPlayBilling: 'Include support for Play Billing (this relies on alpha dependencies)?',
370+
promptPlayBilling: 'Include support for Play Billing?',
374371
promptLocationDelegation: 'Request geolocation permission?',
375372
promptPackageId: 'Application ID:',
376373
promptKeyPath: 'Key store location:',

packages/core/src/lib/features/FeatureManager.ts

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -71,12 +71,7 @@ export class FeatureManager {
7171
}
7272

7373
if (twaManifest.features.playBilling?.enabled) {
74-
if (twaManifest.alphaDependencies?.enabled) {
75-
this.addFeature(new PlayBillingFeature());
76-
} else {
77-
log.error('Skipping PlayBillingFeature. '+
78-
'Enable alphaDependencies to add PlayBillingFeature.');
79-
}
74+
this.addFeature(new PlayBillingFeature());
8075
}
8176

8277
if (twaManifest.features.appsFlyer?.enabled) {

packages/core/src/lib/features/PlayBillingFeature.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ export class PlayBillingFeature extends EmptyFeature {
2424
constructor() {
2525
super('playbilling');
2626

27-
this.buildGradle.dependencies.push('com.google.androidbrowserhelper:billing:1.0.1');
27+
this.buildGradle.dependencies.push('com.google.androidbrowserhelper:billing:1.1.0');
2828

2929
this.androidManifest.components.push(`
3030
<activity

packages/core/src/spec/lib/features/FeatureManagerSpec.ts

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -178,9 +178,6 @@ describe('FeatureManager', () => {
178178
enabled: true,
179179
},
180180
},
181-
alphaDependencies: {
182-
enabled: true,
183-
},
184181
} as TwaManifest;
185182

186183
const playBillingFeature = new PlayBillingFeature();

0 commit comments

Comments
 (0)