import { PrismaClient as lachesisClient } from "@/prisma/schemas/lachesis/generated/lachesis"; import { PrismaClient as artemisClient } from "@/prisma/schemas/artemis/generated/artemis"; const lachesisSingleton = () => { return new lachesisClient(); }; const aremisSingleton = () => { return new artemisClient(); }; declare global { var lachesis: undefined | ReturnType; var artemis: undefined | ReturnType; } export const lachesis = globalThis.lachesis ?? lachesisSingleton(); export const artemis = globalThis.artemis ?? aremisSingleton(); if (process.env.NODE_ENV !== "production") globalThis.lachesis = lachesis;