LibreChat/client/src/components/Chat/Messages
Danny Avila 026890cd27
🛡️ fix: Improve Error Handling and Null Safety in SSE Event Processing (#10751)
* 🔧 fix: Handle null content parts in message processing

- Added checks to filter out null content parts in various message handling functions, ensuring robustness against undefined values.
- Updated the `extractMessageContent`, `useContentHandler`, `useEventHandlers`, and `useStepHandler` hooks to prevent errors caused by null parts.
- Enhanced the `getAllContentText` utility to only include valid content types, improving overall message integrity.

* 🔧 fix: Enhance error handling in event and SSE handlers

- Wrapped critical sections in try-catch blocks within `useEventHandlers` and `useSSE` hooks to improve error management and prevent application crashes.
- Added console error logging for better debugging and tracking of issues during message processing and conversation aborting.
- Ensured that UI states like `setIsSubmitting` and `setShowStopButton` are correctly updated in case of errors, maintaining a consistent user experience.

* 🔧 fix: Filter out null and empty content in message export

- Enhanced the `useExportConversation` hook to filter out null content parts and empty strings during message processing, ensuring only valid content is included in the export.
- This change improves the integrity of exported conversations by preventing unnecessary empty entries in the output.
2025-12-01 14:05:50 -05:00
..
Content 🖼️ fix: resolve stuck pixel animation for image generation (#10716) 2025-11-29 00:23:22 +01:00
ui ♻️ refactor: Replace fontSize Recoil atom with Jotai (#10171) 2025-10-18 05:50:34 -04:00
Feedback.tsx 📦 feat: Move Shared Components to @librechat/client (#8685) 2025-07-27 12:19:01 -04:00
Fork.tsx 📦 feat: Move Shared Components to @librechat/client (#8685) 2025-07-27 12:19:01 -04:00
HoverButtons.tsx 🛡️ fix: Improve Error Handling and Null Safety in SSE Event Processing (#10751) 2025-12-01 14:05:50 -05:00
Message.tsx 🎋 refactor: Improve Message UI State Handling (#9678) 2025-09-17 13:07:56 -04:00
MessageAudio.tsx ⬇️ fix: Image Download Browser Compatibility (#7950) 2025-06-17 21:11:39 -04:00
MessageIcon.tsx 📂 refactor: Cleanup File Filtering Logic, Improve Validation (#10414) 2025-11-10 19:05:30 -05:00
MessageParts.tsx ♻️ refactor: Replace fontSize Recoil atom with Jotai (#10171) 2025-10-18 05:50:34 -04:00
MessagesView.tsx ♻️ refactor: Replace fontSize Recoil atom with Jotai (#10171) 2025-10-18 05:50:34 -04:00
MinimalHoverButtons.tsx 🎨 fix: Correct Read-Only State Logic in Code Editor (#10508) 2025-11-14 12:27:51 -05:00
MinimalMessages.tsx 🔍 feat: Show Messages from Search Result (#2699) 2024-05-14 11:00:01 -04:00
MultiMessage.tsx 🎋 refactor: Improve Message UI State Handling (#9678) 2025-09-17 13:07:56 -04:00
SearchButtons.tsx 🔃 refactor: Streamline Navigation, Message Loading UX (#7118) 2025-04-28 18:18:13 -04:00
SearchMessage.tsx ♻️ refactor: Replace fontSize Recoil atom with Jotai (#10171) 2025-10-18 05:50:34 -04:00
SiblingSwitch.tsx 🎨 refactor: Enhance UI Consistency, Accessibility & Localization (#7788) 2025-06-08 14:00:57 -04:00
SubRow.tsx WIP: Update UI to match Official Style; Vision and Assistants 👷🏽 (#1190) 2023-11-16 10:42:24 -05:00