|
|
@@ -215,7 +215,7 @@ const Home: React.FC<Props> = (props) => {
|
|
|
} else {
|
|
|
setHasFinishedOnboarding(true);
|
|
|
}
|
|
|
- } catch (error) {}
|
|
|
+ } catch (error) { }
|
|
|
};
|
|
|
|
|
|
useEffect(() => {
|
|
|
@@ -369,7 +369,7 @@ const Home: React.FC<Props> = (props) => {
|
|
|
};
|
|
|
|
|
|
const { cluster, baseRoute } = props.match.params as any;
|
|
|
- const { hasPaymentEnabled } = checkIfProjectHasPayment();
|
|
|
+ const { hasPaymentEnabled, refetchPaymentEnabled } = checkIfProjectHasPayment();
|
|
|
const { plan } = useCustomerPlan();
|
|
|
|
|
|
const isTrialExpired = (timestamp: string): boolean => {
|
|
|
@@ -377,7 +377,7 @@ const Home: React.FC<Props> = (props) => {
|
|
|
return true;
|
|
|
}
|
|
|
|
|
|
- const diff = timeFrom("2024-04-17T00:00:00.000Z");
|
|
|
+ const diff = timeFrom(timestamp);
|
|
|
if (diff.when === "future") {
|
|
|
return false;
|
|
|
}
|
|
|
@@ -426,6 +426,7 @@ const Home: React.FC<Props> = (props) => {
|
|
|
setShowBillingModal(false);
|
|
|
}}
|
|
|
onCreate={async () => {
|
|
|
+ await refetchPaymentEnabled({ throwOnError: false, cancelRefetch: false });
|
|
|
setShowBillingModal(false);
|
|
|
}}
|
|
|
/>
|
|
|
@@ -434,6 +435,7 @@ const Home: React.FC<Props> = (props) => {
|
|
|
<BillingModal
|
|
|
trialExpired
|
|
|
onCreate={async () => {
|
|
|
+ await refetchPaymentEnabled({ throwOnError: false, cancelRefetch: false });
|
|
|
setShowBillingModal(false);
|
|
|
}}
|
|
|
/>
|