diff --git a/packages/builder/src/components/deploy/AppActions.svelte b/packages/builder/src/components/deploy/AppActions.svelte index bb950983a6..9ba46832f4 100644 --- a/packages/builder/src/components/deploy/AppActions.svelte +++ b/packages/builder/src/components/deploy/AppActions.svelte @@ -25,6 +25,7 @@ appStore, deploymentStore, sortedScreens, + appPublished, } from "stores/builder" import TourWrap from "components/portal/onboarding/TourWrap.svelte" import { TOUR_STEP_KEYS } from "components/portal/onboarding/tours.js" @@ -45,11 +46,6 @@ $: filteredApps = $appsStore.apps.filter(app => app.devId === application) $: selectedApp = filteredApps?.length ? filteredApps[0] : null - $: latestDeployments = $deploymentStore - .filter(deployment => deployment.status === "SUCCESS") - .sort((a, b) => a.updatedAt > b.updatedAt) - $: isPublished = - selectedApp?.status === "published" && latestDeployments?.length > 0 $: updateAvailable = $appStore.upgradableVersion && $appStore.version && @@ -117,7 +113,7 @@ } const confirmUnpublishApp = async () => { - if (!application || !isPublished) { + if (!application || !$appPublished) { //confirm the app has loaded. return } @@ -204,7 +200,7 @@ >