You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In this version of Next.js iterating headers without awaiting first is still supported to facilitate migration but in a future version you will be required to await the result.
#11930
I set up a new application and was able to set up a new google oath sign in and app without issues but I see this message on the console
In route / headers were iterated implicitly with something likefor...of headers())or[...headers()], or explicitly with headers()[Symbol.iterator](https://github.com/nextauthjs/next-auth/issues/11929). headers()now returns a Promise and the return value should be awaited before attempting to iterate over headers. In this version of Next.js iterating headers without awaiting first is still supported to facilitate migration but in a future version you will be required to await the result. If thisheaders() use is inside an async function await the return value before accessing attempting iteration. If this use is inside a synchronous function then convert the function to async or await the call from outside this function and pass the result in.
In route / a cookie property was accessed directly with cookies().set('authjs.callback-url', ...). cookies() now returns a Promise and the return value should be awaited before accessing properties of the underlying cookies instance. In this version of Next.js direct access to cookies().set('authjs.callback-url', ...) is still supported to facilitate migration but in a future version you will be required to await the result. If this cookies() use is inside an async function await the return value before accessing attempting iteration. If this use is inside a synchronous function then convert the function to async or await the call from outside this function and pass the result in.
In route / a cookie property was accessed directly with cookies().set('authjs.pkce.code_verifier', ...). cookies() now returns a Promise and the return value should be awaited before accessing properties of the underlying cookies instance. In this version of Next.js direct access to cookies().set('authjs.pkce.code_verifier', ...) is still supported to facilitate migration but in a future version you will be required to await the result. If this cookies() use is inside an async function await the return value before accessing attempting iteration. If this use is inside a synchronous function then convert the function to async or await the call from outside this function and pass the result in.
I searched for answers but I'm not sure how to address this issue. The app works as expected but it looks like it might break with future updates
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
Uh oh!
There was an error while loading. Please reload this page.
-
Here are my dependencies
"dependencies": { "@vercel/postgres": "^0.10.0", "next": "15.0.0-canary.173", "next-auth": "5.0.0-beta.22", "react": "^18", "react-dom": "^18" }, "devDependencies": { "@types/node": "^20", "@types/react": "^18", "@types/react-dom": "^18", "eslint": "^8", "eslint-config-next": "14.2.13", "typescript": "^5" }
I set up a new application and was able to set up a new google oath sign in and app without issues but I see this message on the console
In route / headers were iterated implicitly with something likefor...of headers())or[...headers()], or explicitly with headers()[Symbol.iterator](https://github.com/nextauthjs/next-auth/issues/11929). headers()now returns a Promise and the return value should be awaited before attempting to iterate over headers. In this version of Next.js iterating headers without awaiting first is still supported to facilitate migration but in a future version you will be required to await the result. If thisheaders()
use is inside an async function await the return value before accessing attempting iteration. If this use is inside a synchronous function then convert the function to async or await the call from outside this function and pass the resultin.
In route / a cookie property was accessed directly with cookies().set('authjs.callback-url', ...). cookies() now returns a Promise and the return value should be awaited before accessing properties of the underlying cookies instance. In this version of Next.js direct access to cookies().set('authjs.callback-url', ...) is still supported to facilitate migration but in a future version you will be required to await the result. If this cookies() use is inside an async function await the return value before accessing attempting iteration. If this use is inside a synchronous function then convert the function to async or await the call from outside this function and pass the result in.
In route / a cookie property was accessed directly with cookies().set('authjs.pkce.code_verifier', ...). cookies() now returns a Promise and the return value should be awaited before accessing properties of the underlying cookies instance. In this version of Next.js direct access to cookies().set('authjs.pkce.code_verifier', ...) is still supported to facilitate migration but in a future version you will be required to await the result. If this cookies() use is inside an async function await the return value before accessing attempting iteration. If this use is inside a synchronous function then convert the function to async or await the call from outside this function and pass the result in.
I searched for answers but I'm not sure how to address this issue. The app works as expected but it looks like it might break with future updates
Beta Was this translation helpful? Give feedback.
All reactions