diff --git a/src/hooks/useAIComm.ts b/src/hooks/useAIComm.ts index b50f0a0..9011bbc 100644 --- a/src/hooks/useAIComm.ts +++ b/src/hooks/useAIComm.ts @@ -23,7 +23,7 @@ export default function useAIComm( isAIResponding: false, }); - const utils = api.useUtils(); + const utils = api.useContext(); const allSessionMessages = api.userAndAIMessages.getAllSessionUserAndAIMessages.useQuery({ diff --git a/src/hooks/useSessionComm.ts b/src/hooks/useSessionComm.ts index 1c11dcd..c82bf72 100644 --- a/src/hooks/useSessionComm.ts +++ b/src/hooks/useSessionComm.ts @@ -24,7 +24,7 @@ export default function useSessionComm( partnerIsTyping: false, }); - const utils = api.useUtils(); + const utils = api.useContext(); const allSessionMessages = api.userAndUserMessages.getAllSessionUserAndUserMessages.useQuery({ diff --git a/src/pages/maintainer/environments.tsx b/src/pages/maintainer/environments.tsx index ea0641b..829df37 100644 --- a/src/pages/maintainer/environments.tsx +++ b/src/pages/maintainer/environments.tsx @@ -111,7 +111,7 @@ const CreateEnvironment = () => { })); }; - const apiContext = api.useUtils(); + const apiContext = api.useContext(); const updateEnvMutation = api.environment.upsertEnvironment.useMutation( { diff --git a/src/pages/questions/index.tsx b/src/pages/questions/index.tsx index 4844f4b..156ca9b 100644 --- a/src/pages/questions/index.tsx +++ b/src/pages/questions/index.tsx @@ -24,7 +24,7 @@ function Questions() { const [page, setPage] = useState(0); - const getAllQuery = api.useUtils().question.getAllReducedInfinite; + const getAllQuery = api.useContext().question.getAllReducedInfinite; const { data,