| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -3,6 +3,7 @@ import { getSession, useSession } from 'next-auth/client' | |||
| 3 | 3 | function Blog({ data }) { | |
| 4 | 4 | const [session] = useSession() | |
| 5 | 5 | console.log({ session }) | |
| 6 | + | ||
| 6 | 7 | return <h1>Blog page - {data}</h1> | |
| 7 | 8 | } | |
| 8 | 9 | ||
@@ -13,9 +14,7 @@ export async function getServerSideProps(context) { | |||
| 13 | 14 | if (!session) { | |
| 14 | 15 | return { | |
| 15 | 16 | redirect: { | |
| 16 | - destination: `/api/auth/signin?callbackUrl=${encodeURIComponent( | ||
| 17 | - 'http:localhost:3000/blog' | ||
| 18 | - )}`, | ||
| 17 | + destination: '/api/auth/signin?callbackUrl=http://localhost:3000/blog', | ||
| 19 | 18 | permanent: false | |
| 20 | 19 | } | |
| 21 | 20 | } | |
| Back | FazBrowse Home | New Git URL |
0 commit comments