diff options
| author | Alex Pooley (@zuedev) <zuedev@gmail.com> | 2026-05-13 17:28:17 +0100 |
|---|---|---|
| committer | Alex Pooley (@zuedev) <zuedev@gmail.com> | 2026-05-13 17:28:17 +0100 |
| commit | 0e28d43ed23080bb64e24cfe6b710690f74f9c70 (patch) | |
| tree | 000676d5b201c90f6ed3c888f726eeef25372405 /communities/red-right-hand/174bg.net | |
| parent | 43f22c398069bacedd74f4e0814f4ecb6751d81a (diff) | |
| download | unnamed-group-0e28d43ed23080bb64e24cfe6b710690f74f9c70.tar unnamed-group-0e28d43ed23080bb64e24cfe6b710690f74f9c70.tar.gz unnamed-group-0e28d43ed23080bb64e24cfe6b710690f74f9c70.tar.bz2 unnamed-group-0e28d43ed23080bb64e24cfe6b710690f74f9c70.tar.xz unnamed-group-0e28d43ed23080bb64e24cfe6b710690f74f9c70.zip | |
add Discord data page to display user account information
Diffstat (limited to 'communities/red-right-hand/174bg.net')
| -rw-r--r-- | communities/red-right-hand/174bg.net/src/app/secure/discord-data/page.js | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/communities/red-right-hand/174bg.net/src/app/secure/discord-data/page.js b/communities/red-right-hand/174bg.net/src/app/secure/discord-data/page.js new file mode 100644 index 0000000..b906569 --- /dev/null +++ b/communities/red-right-hand/174bg.net/src/app/secure/discord-data/page.js @@ -0,0 +1,24 @@ +import { auth } from "@/auth"; +import { headers } from "next/headers"; + +export default async function DiscordData() { + const session = await auth.api.getSession({ headers: await headers() }); + const accounts = await auth.api.listUserAccounts({ + headers: await headers(), + }); + const discordAccount = accounts?.find((a) => a.provider === "discord"); + + return ( + <main> + <h1>Discord Data</h1> + <p>The following data is stored about your Discord account:</p> + <pre> + {JSON.stringify( + { user: session?.user, account: discordAccount }, + null, + 2, + )} + </pre> + </main> + ); +} |
