Skip to content

Commit edd6fb5

Browse files
committed
Merge branch 'main' of github.com:nextauthjs/next-auth
2 parents fb60554 + 9784dfb commit edd6fb5

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

docs/docs/tutorials/securing-pages-and-api-routes.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -61,8 +61,9 @@ You can protect server side rendered pages using the `unstable_getServerSession`
6161
You need to add this to every server rendered page you want to protect. Be aware, `unstable_getServerSession` takes slightly different arguments than the method it is replacing, `getSession`.
6262

6363
```js title="pages/server-side-example.js"
64-
import { useSession, unstable_getServerSession } from "next-auth/next"
64+
import { unstable_getServerSession } from "next-auth/next"
6565
import { authOptions } from "./api/auth/[...nextauth]"
66+
import {useSession} from "next-auth/react"
6667

6768
export default function Page() {
6869
const { data: session } = useSession()

0 commit comments

Comments
 (0)