From c896f3a5f9b2e3f7f03ad1871b6566f098c0e295 Mon Sep 17 00:00:00 2001 From: stale Date: Sun, 29 May 2022 21:38:34 -0300 Subject: limit flood depth, quiet logs, fix board tx --- assets/client.js | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) (limited to 'assets/client.js') diff --git a/assets/client.js b/assets/client.js index a6a2a73..e50ea9d 100644 --- a/assets/client.js +++ b/assets/client.js @@ -89,7 +89,15 @@ function connect() { function acceptBoard(data) { let vals = new Uint8Array(data); - board = Array.from(vals).reduce((s,c) => s + String.fromCodePoint(c), ""); + board = Array.from(vals).reduce((s,c) => { + let v = String.fromCodePoint(c); + if (v == ' ') { + s = s + " "; + } else { + s = s + v; + } + return s; + }, ""); let last = board[0]; let last_idx = 0; let split_board = []; -- cgit v1.2.3