File tree Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -2,7 +2,7 @@ import type { LoaderFunctionArgs } from "@remix-run/server-runtime";
2
2
import { json } from "@remix-run/server-runtime" ;
3
3
import { GetEvent } from "@trigger.dev/core" ;
4
4
import { z } from "zod" ;
5
- import { prisma } from "~/db.server" ;
5
+ import { $replica } from "~/db.server" ;
6
6
import { authenticateApiRequest } from "~/services/apiAuth.server" ;
7
7
import { apiCors } from "~/utils/apiCors" ;
8
8
@@ -59,7 +59,7 @@ function toJSON(eventRecord: FoundEventRecord): GetEvent {
59
59
type FoundEventRecord = NonNullable < Awaited < ReturnType < typeof findEventRecord > > > ;
60
60
61
61
async function findEventRecord ( eventId : string , environmentId : string ) {
62
- return await prisma . eventRecord . findUnique ( {
62
+ return await $replica . eventRecord . findUnique ( {
63
63
select : {
64
64
eventId : true ,
65
65
name : true ,
You can’t perform that action at this time.
0 commit comments