From ae2d862ccaec4913309cc13dce3a2ef52604720b Mon Sep 17 00:00:00 2001 From: Bernt Christian Egeland Date: Mon, 11 Sep 2023 08:01:14 +0000 Subject: [PATCH] UserExtended type --- src/pages/user-settings/network/index.tsx | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/src/pages/user-settings/network/index.tsx b/src/pages/user-settings/network/index.tsx index 125c7842..29dfe8a4 100644 --- a/src/pages/user-settings/network/index.tsx +++ b/src/pages/user-settings/network/index.tsx @@ -2,12 +2,19 @@ import { type ReactElement } from "react"; import { LayoutAuthenticated } from "~/components/layouts/layout"; import { api } from "~/utils/api"; import { useTranslations } from "use-intl"; +import { User, UserOptions } from "@prisma/client"; + +interface UserExtended extends User { + options: UserOptions & { + deAuthorizeWarning: boolean; + }; +} const UserNetworkSetting = () => { const t = useTranslations("userSettings"); const { mutate: updateSettings } = api.auth.updateUserOptions.useMutation(); - const { data: me, refetch: refetchMe } = api.auth.me.useQuery(); + const { data: me, refetch: refetchMe } = api.auth.me.useQuery(); return (