CQRS.Talk.Refactoring2.Commands._4.Validators.ServiceConsumer.AddSessionDelegate C# (CSharp) Метод

AddSessionDelegate() приватный Метод

private AddSessionDelegate ( AddDelegateCommand command ) : ActionResult
command AddDelegateCommand
Результат ActionResult
        public ActionResult AddSessionDelegate(AddDelegateCommand command)
        {
            var errors = addValidator.GetErrorList(command);

            if (errors.Any())
            {
                //diplay errors to the user
                return View(errors);
            }

            addHandler.Handle(command);
            return RedirectToAction("Index", "SessionDelegate");
        }