From: Christian Heller Date: Mon, 2 Nov 2020 04:52:49 +0000 (+0100) Subject: Remove unnecessary condition. X-Git-Url: https://plomlompom.com/repos/%7B%7Bdb.prefix%7D%7D/%7B%7B%20web_path%20%7D%7D/static/process?a=commitdiff_plain;h=bdc3960561f676f33a627ff77cc15275b7bf1953;p=plomrogue2-experiments Remove unnecessary condition. --- diff --git a/new2/rogue_chat_nocanvas_monochrome.html b/new2/rogue_chat_nocanvas_monochrome.html index 92ac22a..d06eb30 100644 --- a/new2/rogue_chat_nocanvas_monochrome.html +++ b/new2/rogue_chat_nocanvas_monochrome.html @@ -436,7 +436,7 @@ let tui = { }, draw_input: function() { if (this.mode.has_input_prompt) { - for (let y = terminal.rows - this.height_input, i = 0; y < terminal.rows && i < this.input_lines.length; y++, i++) { + for (let y = terminal.rows - this.height_input, i = 0; i < this.input_lines.length; y++, i++) { terminal.write(y, this.window_width, this.input_lines[i]); } } @@ -566,7 +566,7 @@ let explorer = { tui.inputEl.addEventListener('input', (event) => { if (tui.mode.has_input_prompt) { - let max_length = tui.window_width * terminal.rows - tui.input_prompt.length; + let max_length = tui.window_width * terminal.rows - tui.input_prompt.length; if (tui.inputEl.value.length > max_length) { tui.inputEl.value = tui.inputEl.value.slice(0, max_length); };