public ActionResult UpdateBankAccount(long id, BankAccountViewModel viewModel) => _bankAccountCrudHandler .Update(id, viewModel.ToDto()) .Match <ActionResult>( Left: err => BadRequest(err.Message), Right: c => Ok(FromEntity(c)));
public ActionResult CreateBankAccount(BankAccountViewModel viewModel) => _bankAccountCrudHandler .Create(viewModel.ToDto()) .Match <ActionResult>( Left: err => BadRequest(err.Message), Right: Ok);