Skip to content

Commit

Permalink
Update PutUpdates.jl
Browse files Browse the repository at this point in the history
  • Loading branch information
sebibek committed Nov 1, 2023
1 parent c1dba53 commit 2cbbc88
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/webserver/PutUpdates.jl
Original file line number Diff line number Diff line change
Expand Up @@ -94,6 +94,9 @@ function flushclient(client::ClientSession)
try
if client.stream !== nothing
if is_stream_open(client.stream)
if client.stream isa HTTP.WebSockets.WebSocket
client.stream.frame_type = HTTP.WebSockets.WS_BINARY
end
let
lag = client.simulated_lag
(lag > 0) && sleep(lag * (0.5 + rand())) # sleep(0) would yield to the process manager which we dont want
Expand Down

0 comments on commit 2cbbc88

Please sign in to comment.