public OperationResult(EnumOperationResult enumOperationResult, IList <ValidationError> errors) { Status = enumOperationResult; Errors = errors.HasNoItems() ? new List <ValidationError>() : errors; DomainEvents = new List <INotification>(); if (Errors.HasItems() && Status == EnumOperationResult.None) { Status = EnumOperationResult.Error; } }
public OperationResult(EnumOperationResult enumOperationResult) { Status = enumOperationResult; Errors = new List <ValidationError>(); DomainEvents = new List <INotification>(); }