mirror of
https://github.com/MODSetter/SurfSense.git
synced 2026-05-11 16:52:38 +02:00
fix fetchChatDetails return type
This commit is contained in:
parent
05a8bd1be3
commit
d2f00fd328
1 changed files with 2 additions and 1 deletions
|
|
@ -1,5 +1,6 @@
|
|||
import type { Message } from "@ai-sdk/react";
|
||||
import { useCallback, useEffect, useState } from "react";
|
||||
import { Chat, type ChatDetails } from "@/app/dashboard/[search_space_id]/chats/chats-client";
|
||||
import type { ResearchMode } from "@/components/chat";
|
||||
import type { Document } from "@/hooks/use-documents";
|
||||
|
||||
|
|
@ -49,7 +50,7 @@ interface UseChatAPIProps {
|
|||
|
||||
export function useChatAPI({ token, search_space_id }: UseChatAPIProps) {
|
||||
const fetchChatDetails = useCallback(
|
||||
async (chatId: string) => {
|
||||
async (chatId: string): Promise<ChatDetails | null> => {
|
||||
if (!token) return null;
|
||||
|
||||
try {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue