diff --git a/src/components/middle/MessageList.tsx b/src/components/middle/MessageList.tsx index 44aba8ac4..0f188119d 100644 --- a/src/components/middle/MessageList.tsx +++ b/src/components/middle/MessageList.tsx @@ -268,9 +268,13 @@ const MessageList: FC = ({ return; } + const container = containerRef.current; + if (!container) { + return; + } + isScrollingRef.current = true; - const container = containerRef.current!; if (!memoFocusingIdRef.current) { updateStickyDates(container, hasTools);