mirror of
https://codeberg.org/MarkusThielker/next-ory.git
synced 2025-04-16 23:51:18 +00:00
NORY-22: fix typing problems
This commit is contained in:
parent
9faba3dc29
commit
63affda5fa
1 changed files with 7 additions and 17 deletions
|
@ -11,21 +11,11 @@ export default async function UserDetailsPage({ params }: { params: Promise<{ id
|
||||||
const identityId = (await params).id;
|
const identityId = (await params).id;
|
||||||
|
|
||||||
const identityApi = await getIdentityApi();
|
const identityApi = await getIdentityApi();
|
||||||
const identity = await identityApi.getIdentity({
|
const identity = await identityApi.getIdentity({ id: identityId })
|
||||||
id: identityId,
|
.then((response) => {
|
||||||
includeCredential: [
|
console.log('identity', response.data);
|
||||||
'code',
|
return response.data;
|
||||||
'code_recovery',
|
})
|
||||||
'link_recovery',
|
|
||||||
'lookup_secret',
|
|
||||||
'oidc',
|
|
||||||
'passkey',
|
|
||||||
'password',
|
|
||||||
'totp',
|
|
||||||
'webauthn',
|
|
||||||
],
|
|
||||||
})
|
|
||||||
.then((response) => response.data)
|
|
||||||
.catch(() => {
|
.catch(() => {
|
||||||
console.log('Identity not found');
|
console.log('Identity not found');
|
||||||
});
|
});
|
||||||
|
@ -85,11 +75,11 @@ export default async function UserDetailsPage({ params }: { params: Promise<{ id
|
||||||
</TableHeader>
|
</TableHeader>
|
||||||
<TableBody>
|
<TableBody>
|
||||||
{
|
{
|
||||||
Object.entries(identity.credentials).map(([key, value]) => {
|
Object.entries(identity.credentials!).map(([key, value]) => {
|
||||||
return (
|
return (
|
||||||
<TableRow key={key}>
|
<TableRow key={key}>
|
||||||
<TableCell>{key}</TableCell>
|
<TableCell>{key}</TableCell>
|
||||||
<TableCell>{value.identifiers[0]}</TableCell>
|
<TableCell>{value.identifiers![0]}</TableCell>
|
||||||
</TableRow>
|
</TableRow>
|
||||||
);
|
);
|
||||||
})
|
})
|
||||||
|
|
Loading…
Add table
Reference in a new issue