diff --git a/src/EventHub.Application/Events/EventAppService.cs b/src/EventHub.Application/Events/EventAppService.cs index 18811a5..e82aa9c 100644 --- a/src/EventHub.Application/Events/EventAppService.cs +++ b/src/EventHub.Application/Events/EventAppService.cs @@ -409,11 +409,10 @@ namespace EventHub.Events var userQueryable = await _userRepository.GetQueryableAsync(); var query = userQueryable - .Where(u => userNames.Any(p => p == u.UserName)) + .Where(u => userNames.Contains(u.UserName)) .Select(x => x.Id); var userIds = await AsyncExecuter.ToListAsync(query); - if (userIds.Count != userNames.Count) { await CheckIfValidUserNamesAsync(userNames);