public ActionResult Register()
 {
     var command = new RegisterAccountCommand {AccountId = Guid.NewGuid()};
     return View(command);
 }
 public ActionResult Register(RegisterAccountCommand command)
 {
     Configuration.Instance().Bus.Handle(command);
     return View("Registered");
 }
 public void Handle(RegisterAccountCommand command)
 {
     var account = new Account(command.AccountId, command.Name, command.Email, command.InitialBalance);
     _repository.Save(account);
 }