public async Task<UserProfile> Query(UserProfileById query) { UserView view = await _store.FindByIdAsync(query.UserId); UserProfile profile = new UserProfile { Id = view.Id, Email = view.Email, }; return profile; }
public async Task <UserProfile> Query(UserProfileById query) { UserView view = await _store.FindByIdAsync(query.UserId); return(view?.ToModel()); }