From fbc4f7244a19a4fff2fb69f1ab74d466a44df205 Mon Sep 17 00:00:00 2001 From: teisnp Date: Sun, 4 Feb 2024 20:00:06 +0100 Subject: [PATCH] simple check for empty url return checkout session --- apps/dashboard/src/api/endpoints/teams.ts | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/apps/dashboard/src/api/endpoints/teams.ts b/apps/dashboard/src/api/endpoints/teams.ts index cd0ae2d..0bb5179 100644 --- a/apps/dashboard/src/api/endpoints/teams.ts +++ b/apps/dashboard/src/api/endpoints/teams.ts @@ -161,5 +161,7 @@ export async function postCreateCheckoutSession( priceLookupKey, }); const body = (await res).data; - window.location.href = body; + if (body != "") { + window.location.href = body; + } }