From ae592ba1ebe37520ba66863eeba0717eebae797e Mon Sep 17 00:00:00 2001 From: Youen Date: Thu, 18 May 2023 18:06:21 +0200 Subject: [PATCH] Reduced stream poll interval --- src/static/log-stream.js | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/static/log-stream.js b/src/static/log-stream.js index 50516fe..26a2a29 100644 --- a/src/static/log-stream.js +++ b/src/static/log-stream.js @@ -25,7 +25,11 @@ function log_stream(element, logUrl) { } } else { - setTimeout(fetchMore, 100); + let delay = 500; + if(json.new_output != '') { + delay = 100; + } + setTimeout(fetchMore, delay); } }); }