Use static import for nanoid in webhook files

Co-authored-by: Siumauricio <47042324+Siumauricio@users.noreply.github.com>
This commit is contained in:
copilot-swe-agent[bot]
2025-12-31 06:13:28 +00:00
parent 806621e173
commit cb5800f61b
2 changed files with 2 additions and 2 deletions

View File

@@ -5,6 +5,7 @@ import {
shouldDeploy,
} from "@dokploy/server";
import { eq } from "drizzle-orm";
import { nanoid } from "nanoid";
import type { NextApiRequest, NextApiResponse } from "next";
import { db } from "@/server/db";
import { applications } from "@/server/db/schema";
@@ -231,7 +232,6 @@ export default async function handler(
}
try {
const { nanoid } = await import("nanoid");
const jobId = nanoid();
const jobData: DeploymentJob = {
applicationId: application.applicationId as string,

View File

@@ -1,5 +1,6 @@
import { IS_CLOUD, shouldDeploy } from "@dokploy/server";
import { eq } from "drizzle-orm";
import { nanoid } from "nanoid";
import type { NextApiRequest, NextApiResponse } from "next";
import { db } from "@/server/db";
import { compose } from "@/server/db/schema";
@@ -168,7 +169,6 @@ export default async function handler(
}
try {
const { nanoid } = await import("nanoid");
const jobId = nanoid();
const jobData: DeploymentJob = {
composeId: composeResult.composeId as string,