mirror of
https://github.com/Novaloop-AG/healthchat-web.git
synced 2026-11-09 07:58:23 +00:00
Null-guard for missing root event in thread panel (#7067)
This commit is contained in:
@@ -81,7 +81,7 @@ const useFilteredThreadsTimelinePanel = ({
|
|||||||
// The proper list order should be top-to-bottom, like in social-media newsfeeds.
|
// The proper list order should be top-to-bottom, like in social-media newsfeeds.
|
||||||
filteredThreads.reverse().forEach(([id, thread]) => {
|
filteredThreads.reverse().forEach(([id, thread]) => {
|
||||||
const event = thread.rootEvent;
|
const event = thread.rootEvent;
|
||||||
if (timelineSet.findEventById(event.getId()) || event.status !== null) return;
|
if (!event || timelineSet.findEventById(event.getId()) || event.status !== null) return;
|
||||||
timelineSet.addEventToTimeline(
|
timelineSet.addEventToTimeline(
|
||||||
event,
|
event,
|
||||||
timelineSet.getLiveTimeline(),
|
timelineSet.getLiveTimeline(),
|
||||||
|
|||||||
Reference in New Issue
Block a user