I have added the cors.ts file to our project and added the middleware function to use cors, however when I run yarn dev I the following error
TypeError: Cannot read properties of undefined (reading 'set')
The error comes from the cors function inside cors.ts. We have not modified the code.
We are on NextJS 12.1.0. Any help here is apprecaited.
I have added the
cors.tsfile to our project and added the middleware function to use cors, however when I runyarn devI the following errorThe error comes from the cors function inside cors.ts. We have not modified the code.
We are on NextJS 12.1.0. Any help here is apprecaited.