Skip to content

Commit

Permalink
Update IncidentSummary.cs
Browse files Browse the repository at this point in the history
  • Loading branch information
stavris8894 authored and oskardudycz committed Nov 29, 2022
1 parent fbfd68f commit c7597ae
Showing 1 changed file with 3 additions and 3 deletions.
Expand Up @@ -50,14 +50,14 @@ public class CustomerIncidentsSummaryGrouper: IAggregateGrouper<Guid>
{
private readonly Type[] eventTypes =
{
typeof(IEvent<IncidentResolved>), typeof(IEvent<ResolutionAcknowledgedByCustomer>),
typeof(IEvent<IncidentClosed>)
typeof(IncidentResolved), typeof(ResolutionAcknowledgedByCustomer),
typeof(IncidentClosed)
};

public async Task Group(IQuerySession session, IEnumerable<IEvent> events, ITenantSliceGroup<Guid> grouping)
{
var filteredEvents = events
.Where(ev => eventTypes.Contains(ev.GetType()))
.Where(ev => eventTypes.Contains(ev.EventType))
.ToList();

if (!filteredEvents.Any())
Expand Down

0 comments on commit c7597ae

Please sign in to comment.