From cbad7f700872a200a2a99594b651ef7f785cca2a Mon Sep 17 00:00:00 2001 From: Timm Fitschen <t.fitschen@indiscale.com> Date: Mon, 18 Mar 2024 04:48:59 +0100 Subject: [PATCH] WIP: OAuth authn --- pages/_app.tsx | 2 +- src/components/fdos/create.tsx | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/pages/_app.tsx b/pages/_app.tsx index a6e5e3d..2f98e8b 100644 --- a/pages/_app.tsx +++ b/pages/_app.tsx @@ -102,7 +102,7 @@ const App = (props: React.PropsWithChildren) => { return null }, getIdentity: async () => { - console.log('getIdentity') + console.log('getIdentity', data) if (data?.user) { const { user } = data return { diff --git a/src/components/fdos/create.tsx b/src/components/fdos/create.tsx index 2eea699..83d93b7 100644 --- a/src/components/fdos/create.tsx +++ b/src/components/fdos/create.tsx @@ -142,7 +142,7 @@ const StepData: React.FC<any> = ({ register, errors }) => { export const FdoCreate: React.FC<IResourceComponentsProps> = () => { const identity = useGetIdentity<any>() console.log('identity', identity) - const accessToken = identity.data?.data?.account?.accessToken + const accessToken = identity.data?.data?.accessToken console.log('accessToken: ', accessToken) const formRet = useStepsForm<any, HttpError, any>({ defaultValues: { repository: '', profile: '' }, refineCoreProps: { meta: { headers: { Authentication: `Bearer ${accessToken}` } } } }) -- GitLab