Skip to content

Commit

Permalink
chore: debug getProviders
Browse files Browse the repository at this point in the history
  • Loading branch information
sobird committed Nov 21, 2024
1 parent d32d3f4 commit f6d4fbd
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
3 changes: 2 additions & 1 deletion app/(authentication)/signin/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
import { Divider, Typography } from 'antd';
import { Metadata } from 'next';
import Link from 'next/link';
import { getProviders } from 'next-auth/react';

import Providers from '@/components/providers';

Expand All @@ -24,7 +25,7 @@ interface SearchParams {

const SigninPage: AppPage<{}, SearchParams> = async ({ searchParams }) => {
const { callbackUrl } = await searchParams;

console.log('await getProviders() page:', await getProviders());
return (
<>
<h1>欢迎登录</h1>
Expand Down
1 change: 1 addition & 0 deletions components/providers/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ interface ProvidersProps {

const Providers:React.FC<ProvidersProps> = async ({ callbackUrl }) => {
const csrfToken = await getCsrfAuthToken();
console.log('await getProviders()', await getProviders());
const providers = Object.entries(await getProviders() || {}).map(([, item]) => {
return item;
}).filter((item) => {
Expand Down

0 comments on commit f6d4fbd

Please sign in to comment.