public static void SetLogEngine(ILogEngine engine) { if (engine == null) { return; } var prevItems = Log?.GetPendingItems(); Log = engine; if (prevItems != null) { engine.EnqueueItemsArray(prevItems); } }