Explorar o código

* Take into account SendOutputToBrowser

Michael Van Canneyt hai 5 meses
pai
achega
57c841e471
Modificáronse 1 ficheiros con 2 adicións e 1 borrados
  1. 2 1
      packages/wasi/src/wasiworkerthreadhost.pas

+ 2 - 1
packages/wasi/src/wasiworkerthreadhost.pas

@@ -673,7 +673,8 @@ end;
 
 procedure TWorkerThreadRunnerApplication.HandleConsoleWrite(Sender: TObject; aOutput: string);
 begin
-  ConsoleChannel.postMessage(TWorkerConsoleCommand.Create(aOutput));
+  if SendOutputToBrowser then
+    ConsoleChannel.postMessage(TWorkerConsoleCommand.Create(aOutput));
 end;
 
 function TWorkerThreadRunnerApplication.CreateWorkerThreadSupport(aEnv : TPas2JSWasiEnvironment) : TWorkerThreadSupport;