Fixes n+1 query on UserRepository.GetByQuery