Skip to content

Commit

Permalink
Fix
Browse files Browse the repository at this point in the history
  • Loading branch information
istarkov committed Jul 26, 2024
1 parent b4250c4 commit d885f81
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 8 deletions.
19 changes: 11 additions & 8 deletions apps/builder/app/shared/db/canvas.server.ts
Original file line number Diff line number Diff line change
Expand Up @@ -35,14 +35,17 @@ export const loadProductionCanvasData = async (

// Check that build deployment domains are still active and verified
// for examle: redeploy created few days later
const domains = deployment.domains.filter((domain) =>
currentProjectDomains.some(
(projectDomain) =>
projectDomain.domain.domain === domain &&
projectDomain.domain.status === "ACTIVE" &&
projectDomain.verified
)
);
const domains =
deployment.destination === "static"
? []
: deployment.domains.filter((domain) =>
currentProjectDomains.some(
(projectDomain) =>
projectDomain.domain.domain === domain &&
projectDomain.domain.status === "ACTIVE" &&
projectDomain.verified
)
);

const page = findPageByIdOrPath("/", build.pages);

Expand Down
1 change: 1 addition & 0 deletions packages/domain/src/trpc/domain.ts
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,7 @@ export const domainRouter = router({
destination: input.destination,
name: `${project.id}.zip`,
assetsDomain: project.domain,
templates: ["ssg"],
},
},
ctx
Expand Down
1 change: 1 addition & 0 deletions packages/sdk/src/schema/deployment.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ export const Deployment = z.union([
destination: z.literal("static"),
name: z.string(),
assetsDomain: z.string(),
templates: z.array(z.string()),
}),
z.object({
destination: z.literal("saas").optional(),
Expand Down

0 comments on commit d885f81

Please sign in to comment.