0d30aab5 months ago21 lines · 555 B| 1 | import { getAuth } from "@struxa/auth"; |
| 2 | import type { NextRequest |
| 3 | |
| 4 | export async function createContext |
| 5 | const auth = |
| 6 | const session = |
| 7 | headers: req.headers |
| 8 | }); |
| 9 | const ip = |
| 10 | req.headers.get |
| 11 | req.headers.get |
| 12 | null; |
| 13 | return { |
| 14 | auth: null, |
| 15 | session, |
| 16 | ip, |
| 17 | revalidate: undefined as ( |
| 18 | }; |
| 19 | } |
| 20 | |
| 21 | export type Context |