mirror of
https://github.com/4ian/GDevelop.git
synced 2025-10-15 10:19:04 +00:00
Fix message asking to check Apple/Google account for subscription not always shown (#6761)
- This was the case when the app was opened from https://editor.gdevelop.io?initial-dialog=subscription
This commit is contained in:
@@ -16,6 +16,7 @@ import {
|
||||
type SubscriptionPlanWithPricingSystems,
|
||||
type SubscriptionPlanPricingSystem,
|
||||
type Subscription,
|
||||
hasMobileAppStoreSubscriptionPlan,
|
||||
} from '../../Utils/GDevelopServices/Usage';
|
||||
import EmptyMessage from '../../UI/EmptyMessage';
|
||||
import { showErrorBox } from '../../UI/Messages/MessageBox';
|
||||
@@ -745,6 +746,39 @@ export default function SubscriptionDialog({
|
||||
</EmptyMessage>
|
||||
</ColumnStackLayout>
|
||||
</Dialog>
|
||||
{hasMobileAppStoreSubscriptionPlan(
|
||||
authenticatedUser.subscription
|
||||
) && (
|
||||
<Dialog
|
||||
open
|
||||
title={
|
||||
<Trans>
|
||||
Subscription with the Apple App store or Google Play store
|
||||
</Trans>
|
||||
}
|
||||
maxWidth="sm"
|
||||
cannotBeDismissed
|
||||
actions={[
|
||||
<FlatButton
|
||||
key="close"
|
||||
label={
|
||||
<Trans>
|
||||
Understood, I'll check my Apple or Google account
|
||||
</Trans>
|
||||
}
|
||||
onClick={onClose}
|
||||
/>,
|
||||
]}
|
||||
>
|
||||
<Text>
|
||||
<Trans>
|
||||
The subscription of this account was done using Apple or
|
||||
Google Play. Connect on your account on your Apple or Google
|
||||
device to manage it.
|
||||
</Trans>
|
||||
</Text>
|
||||
</Dialog>
|
||||
)}
|
||||
{!authenticatedUser.authenticated &&
|
||||
authenticatedUser.loginState !== 'loggingIn' && (
|
||||
<Dialog
|
||||
|
@@ -78,14 +78,6 @@ export const SubscriptionSuggestionProvider = ({
|
||||
|
||||
// Would present App Store screen.
|
||||
} else {
|
||||
if (hasMobileAppStoreSubscriptionPlan(authenticatedUser.subscription)) {
|
||||
showAlert({
|
||||
title: t`Subscription with the Apple App store or Google Play store`,
|
||||
message: t`The subscription of this account was done using Apple or Google Play. Connect on your account on your Apple or Google device to manage it.`,
|
||||
});
|
||||
return;
|
||||
}
|
||||
|
||||
setFilter(subscriptionsFilter || null);
|
||||
setAnalyticsMetadata(metadata);
|
||||
}
|
||||
|
Reference in New Issue
Block a user