Method Safe
Safe(ILogWriter?)
Ensures that a non-null ILogWriter instance is returned.
public static ILogWriter Safe(ILogWriter? writer = null)
Parameters
writerILogWriterThe ILogWriter instance to validate. Can be null.
Returns
- ILogWriter
The provided
writerif it is not null; otherwise, the current default writer or a debug writer.