Closed oga-sven closed 1 year ago
Fyi i did now fix it by splitting the auth into a local function and letting that do the logic like the docs. But it seems weird to me that this is the intended way
Reproduction repo plzzz
Please reopen with a reproduction repo if the issue persists
What happened?
When trying to upload an image, i get an error that an imported util is not defined. I tried other solutions and imports but they get the same error. none of the imported functions work
What did you expect to happen?
I expected my utils to be defined
Version
"uploadthing": "^5.2.1"
Reproduction Steps
Below i have pasted my middleware. Without the auth stuff it works perfectly fine, I am using pnpm. Im not completely sure what to provide more than the middleware as its not something very specific. No matter what i import, be it a custom function from a different file or something from a library, i always get undefined.
This is only the case for imports, as same file functions work. more in the code below
Reproduction Repository
Relevant log output