83bc1c616 days ago24 lines · 612 B| 1 | import { viewPaths } from "@better-auth-ui/core"; |
| 2 | import { notFound } |
| 3 | |
| 4 | import { Auth } |
| 5 | |
| 6 | // The organization plugin adds the page an emailed invitation links to. |
| 7 | const validAuthPaths = new |
| 8 | ...Object.values( |
| 9 | "accept-invitation", |
| 10 | ]); |
| 11 | |
| 12 | export default async function |
| 13 | const { path |
| 14 | |
| 15 | if (!validAuthPaths.has |
| 16 | notFound(); |
| 17 | } |
| 18 | |
| 19 | return ( |
| 20 | <div className="flex flex-1 items-center justify-center p-4 md:p-6 |
| 21 | <Auth path={ |
| 22 | </div> |
| 23 | ); |
| 24 | } |