From 8c62663015dbbaa6f1575c8dc8e6498d955c6184 Mon Sep 17 00:00:00 2001 From: NGGJamie <6971628+NGGJamie@users.noreply.github.com> Date: Thu, 14 Jan 2021 05:35:04 -0600 Subject: [PATCH] Fixes [unbold] directive in ANSI Previously, [unbold] was not sanitized and would send the client raw control characters, without applying the wanted effect. This fixes that to make the ANSI code work correctly. --- public/js/replacements.js | 1 + 1 file changed, 1 insertion(+) diff --git a/public/js/replacements.js b/public/js/replacements.js index ef3b935..4836871 100644 --- a/public/js/replacements.js +++ b/public/js/replacements.js @@ -29,6 +29,7 @@ var subs = [ { 'type' : 'ansi', 'pattern' : /\u001b\[1m/g, 'replacement' : '' }, { 'type' : 'ansi', 'pattern' : /\u001b\[2m/g, 'replacement' : '' }, { 'type' : 'ansi', 'pattern' : /\u001b\[0m/g, 'replacement' : '' }, + { 'type' : 'ansi', 'pattern' : /\u001b\[22m/g, 'replacement' : '' }, { 'type' : 'ansi', 'pattern' : /\u001b\[40m/g, 'replacement' : '' }, { 'type' : 'ansi', 'pattern' : /\u001b\[41m/g, 'replacement' : '' }, { 'type' : 'ansi', 'pattern' : /\u001b\[42m/g, 'replacement' : '' },