@@ -456,6 +456,8 @@ const AssignUnassignEventView = ({ event }: { event: AssignEvent | UnassignEvent
456456 const { actor } = event ;
457457 const assignees = ( event as AssignEvent ) . assignees || [ ] ;
458458 const unassignees = ( event as UnassignEvent ) . unassignees || [ ] ;
459+ const joinedAssignees = joinWithAnd ( assignees . map ( a => < AuthorLink key = { `${ a . id } a` } for = { a } /> ) ) ;
460+ const joinedUnassignees = joinWithAnd ( unassignees . map ( a => < AuthorLink key = { `${ a . id } u` } for = { a } /> ) ) ;
459461
460462 // Check if actor is assigning/unassigning themselves
461463 const isSelfAssign = assignees . length === 1 && assignees [ 0 ] . login === actor . login ;
@@ -464,13 +466,13 @@ const AssignUnassignEventView = ({ event }: { event: AssignEvent | UnassignEvent
464466 let message : JSX . Element ;
465467 if ( assignees . length > 0 && unassignees . length > 0 ) {
466468 // Handle mixed case with potential self-assignment
467- const assignMessage = isSelfAssign ? < > assigned themselves</ > : < > assigned { joinWithAnd ( assignees . map ( a => < AuthorLink key = { ` ${ a . id } a` } for = { a } /> ) ) } </ > ;
468- const unassignMessage = isSelfUnassign ? < > removed their assignment</ > : < > unassigned { joinWithAnd ( unassignees . map ( a => < AuthorLink key = { ` ${ a . id } u` } for = { a } /> ) ) } </ > ;
469+ const assignMessage = isSelfAssign ? < > assigned themselves</ > : < > assigned { joinedAssignees } </ > ;
470+ const unassignMessage = isSelfUnassign ? < > removed their assignment</ > : < > unassigned { joinedUnassignees } </ > ;
469471 message = < > { assignMessage } and { unassignMessage } </ > ;
470472 } else if ( assignees . length > 0 ) {
471- message = isSelfAssign ? < > assigned themselves</ > : < > assigned { joinWithAnd ( assignees . map ( a => < AuthorLink key = { ` ${ a . id } a` } for = { a } /> ) ) } </ > ;
473+ message = isSelfAssign ? < > assigned themselves</ > : < > assigned { joinedAssignees } </ > ;
472474 } else {
473- message = isSelfUnassign ? < > removed their assignment</ > : < > unassigned { joinWithAnd ( unassignees . map ( a => < AuthorLink key = { ` ${ a . id } u` } for = { a } /> ) ) } </ > ;
475+ message = isSelfUnassign ? < > removed their assignment</ > : < > unassigned { joinedUnassignees } </ > ;
474476 }
475477
476478 return (
0 commit comments