public ICommandResult Handle(CriarGitHubCommand command) { CommandResult retorno; try { var git = new GitHub(command.Id, command.Node_Id, command.Name, command.Full_Name, command.Description, command.Pushed_At, command.Created_At, command.Updated_At, command.Owner, command.Html_Url, command.Language); var codigoOwner = Guid.NewGuid(); _repository.GravarOwner(git.Owner, codigoOwner); _repository.Gravar(git, codigoOwner); retorno = Sucesso(null); } catch (Exception ex) { retorno = Falha(ex.Message); } return(retorno); }