public TwitterAccountDto UpdateAccount(int id, UpdateTwitterAccountDto dto) { var socialAccount = _socialAccountService.FindAccount(id, SocialUserSource.Twitter); if (socialAccount == null) { throw SocialExceptions.TwitterAccountNotExists(id); } socialAccount = Mapper.Map(dto, socialAccount); _socialAccountService.Update(socialAccount); return(Mapper.Map <TwitterAccountDto>(socialAccount)); }
public TwitterAccountDto UpdateAccount(int id, [Required] UpdateTwitterAccountDto dto) { var account = _appService.UpdateAccount(id, dto); return(account); }