diff --git a/src/hooks/internal/useFlowInternal.ts b/src/hooks/internal/useFlowInternal.ts index 5c8b46b..bec3236 100644 --- a/src/hooks/internal/useFlowInternal.ts +++ b/src/hooks/internal/useFlowInternal.ts @@ -38,7 +38,7 @@ export const useFlowInternal = () => { * Retrieves the conversation flow for the chatbot. */ const getFlow = useCallback(() => { - return flowRef.current ?? {}; + return flowRef?.current ?? {}; }, [flowRef]);