namespace ZB.MOM.WW.Audit;

/// <summary>Writer that discards events. Default when audit is disabled, and useful in tests.</summary>
public sealed class NoOpAuditWriter : IAuditWriter
{
    /// <summary>Shared singleton instance.</summary>
    public static readonly NoOpAuditWriter Instance = new();
    private NoOpAuditWriter() { }

    /// <inheritdoc />
    public Task WriteAsync(AuditEvent evt, CancellationToken ct = default) => Task.CompletedTask;
}
