diff --git a/app/routes/users/components/user-row.tsx b/app/routes/users/components/user-row.tsx index 529e236..a13df3f 100644 --- a/app/routes/users/components/user-row.tsx +++ b/app/routes/users/components/user-row.tsx @@ -64,7 +64,7 @@ function mapRoleToName(role: string) { case 'invalid-oidc': return
Invalid
; case 'no-role': - returnNo Role
; + returnUnregistered
; case 'owner': return 'Owner'; case 'admin': diff --git a/app/routes/users/overview.tsx b/app/routes/users/overview.tsx index 62d9fd4..45d908a 100644 --- a/app/routes/users/overview.tsx +++ b/app/routes/users/overview.tsx @@ -3,7 +3,6 @@ import { PersonIcon } from '@primer/octicons-react'; import { useEffect, useState } from 'react'; import type { ActionFunctionArgs, LoaderFunctionArgs } from 'react-router'; import { useLoaderData, useSubmit } from 'react-router'; -import { ClientOnly } from 'remix-utils/client-only'; import Attribute from '~/components/Attribute'; import Card from '~/components/Card'; import { ErrorPopup } from '~/components/Error'; @@ -54,6 +53,9 @@ export async function loader({ return role ?? 'no-role'; } + // No role means the user is not registered in Headplane, but they + // are in Headscale. We also need to handle what happens if someone + // logs into the UI and they don't have a Headscale setup. return 'no-role'; });