From 02ee8a670cdb5ae8b09156c4a2149487f4aa8304 Mon Sep 17 00:00:00 2001 From: Rapougnac Date: Fri, 15 Mar 2024 18:43:38 +0100 Subject: [PATCH] fix: Intialize logging sooner to prevent missed logs (#637) --- lib/src/plugin/logging.dart | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/lib/src/plugin/logging.dart b/lib/src/plugin/logging.dart index 7567ef32e..2b29df65d 100644 --- a/lib/src/plugin/logging.dart +++ b/lib/src/plugin/logging.dart @@ -50,7 +50,9 @@ class Logging extends NyxxPlugin { StringSink? stdout, StringSink? stderr, }) : stdout = stdout ?? io.stdout, - stderr = stderr ?? io.stderr; + stderr = stderr ?? io.stderr { + _listenIfNeeded(); + } static int _clients = 0; @@ -130,7 +132,6 @@ class Logging extends NyxxPlugin { } _clients++; - _listenIfNeeded(); } @override