Skip to content

Commit

Permalink
chore(website): use finally
Browse files Browse the repository at this point in the history
  • Loading branch information
IgnisDa committed Oct 29, 2024
1 parent 0e58276 commit 11f13a4
Showing 1 changed file with 3 additions and 6 deletions.
9 changes: 3 additions & 6 deletions apps/website/app/entry.server.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -14,15 +14,12 @@ const migrationClient = postgres(serverVariables.DATABASE_URL, { max: 1 });
migrate(drizzle(migrationClient), {
migrationsFolder: "app/drizzle/migrations",
})
.then(() => {
migrationClient.end();
console.log("Database migrations complete");
})
.then(() => console.log("Database migrations complete"))
.catch((error) => {
console.error("Database migrations failed", error);
migrationClient.end();
process.exit(1);
});
})
.finally(() => migrationClient.end());

const ABORT_DELAY = 5_000;

Expand Down

0 comments on commit 11f13a4

Please sign in to comment.