From 8f4e54f19561375e3f06ddc703f71678a146a036 Mon Sep 17 00:00:00 2001 From: Suzanne Soy Date: Wed, 23 Jun 2021 18:41:53 +0100 Subject: [PATCH] fixup! Fixed bug with textareas lacking syntax highlighting on Chrome mobile (hopefully) --- git-tutorial.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/git-tutorial.js b/git-tutorial.js index 16d967a..a92f220 100644 --- a/git-tutorial.js +++ b/git-tutorial.js @@ -941,7 +941,7 @@ function ___functions_to_html(section) { // Since CodeMirror replaces the textareas, the collection of HTML nodes // is automatically updated in some browsers, and the indices become wrong // after a replacement, so we copy the HTML element collection to a proper array. - for (var j = 0; j < ta.length; j++) { ta.push(tas[j]); } + for (var j = 0; j < tas.length; j++) { ta.push(tas[j]); } for (var j = 0; j < ta.length; j++) { if (___ancestor(ta[j], 'section') == section) { var lines = ta[j].value.split('\n');