Can't have runtime edge code on "top level" despite it was the same on the previous version of file

For some reason when I try to build my pages into a worker with opennextjs when I'm migrating from next-auth to better-auth, I get the
`getRequestContext` is being called at the top level of a route file, this is not supported
`getRequestContext` is being called at the top level of a route file, this is not supported
error, despite before when I still use next-auth, the runtime edge code was also on the top, literally. I'm losing my mind over this, does anyone know where I've gone wrong? (Image information on each image's alt)
route.ts (api/auth/[...all])
auth.ts
0 Replies
No replies yetBe the first to reply to this messageJoin

Did you find this page helpful?