public async Task <GamePick> UpdateAsync(PickEmLeagueModels.Models.GamePick gamePick)
        {
            var entity = await GetAsync(gamePick.Id);

            _mapper.Map(gamePick, entity);
            _gamePicks[entity.Id] = entity;
            return(entity);
        }
예제 #2
0
        public async Task <GamePick> UpdateAsync(PickEmLeagueModels.Models.GamePick gamePick)
        {
            var entity = await GetAsync(gamePick.Id);

            _mapper.Map(gamePick, entity);
            var result = _dbContext.SaveChanges();

            return(entity);
        }