File tree Expand file tree Collapse file tree 1 file changed +3
-2
lines changed
x-pack/plugins/security_solution/public/timelines/components/timeline/notes_tab_content Expand file tree Collapse file tree 1 file changed +3
-2
lines changed Original file line number Diff line number Diff line change 44 * you may not use this file except in compliance with the Elastic License.
55 */
66
7- import { pick , uniqBy } from 'lodash/fp' ;
7+ import { filter , pick , uniqBy } from 'lodash/fp' ;
88import {
99 EuiAvatar ,
1010 EuiFlexGroup ,
@@ -139,7 +139,8 @@ const NotesTabContentComponent: React.FC<NotesTabContentProps> = ({ timelineId }
139139 const isImmutable = timelineStatus === TimelineStatus . immutable ;
140140 const notes : TimelineResultNote [ ] = useDeepEqualSelector ( getNotesAsCommentsList ) ;
141141
142- const participants = useMemo ( ( ) => uniqBy ( 'updatedBy' , notes ) , [ notes ] ) ;
142+ // filter for savedObjectId to make sure we don't display `elastic` user while saving the note
143+ const participants = useMemo ( ( ) => uniqBy ( 'updatedBy' , filter ( 'savedObjectId' , notes ) ) , [ notes ] ) ;
143144
144145 const associateNote = useCallback (
145146 ( noteId : string ) => dispatch ( timelineActions . addNote ( { id : timelineId , noteId } ) ) ,
You can’t perform that action at this time.
0 commit comments