update deno commons mod
This commit is contained in:
@@ -272,11 +272,11 @@ function parseColorTokens(message: string, renderColor: boolean): ColorToken[] {
|
|||||||
const nextC = (i + 1) < messageLength
|
const nextC = (i + 1) < messageLength
|
||||||
? message.charAt(i + 1)
|
? message.charAt(i + 1)
|
||||||
: null;
|
: null;
|
||||||
const nextNexC = (i + 2) < messageLength
|
const nextNextC = (i + 2) < messageLength
|
||||||
? message.charAt(i + 2)
|
? message.charAt(i + 2)
|
||||||
: null;
|
: null;
|
||||||
if (noEscape) {
|
if (noEscape) {
|
||||||
if (c === "]" && nextC === "]" && nextNexC === "]") {
|
if (c === "]" && nextC === "]" && nextNextC === "]") {
|
||||||
// end no escape
|
// end no escape
|
||||||
noEscape = false;
|
noEscape = false;
|
||||||
i += 2;
|
i += 2;
|
||||||
@@ -301,7 +301,7 @@ function parseColorTokens(message: string, renderColor: boolean): ColorToken[] {
|
|||||||
} else if (nextC == "/") {
|
} else if (nextC == "/") {
|
||||||
inColorEnd = true;
|
inColorEnd = true;
|
||||||
i++;
|
i++;
|
||||||
} else if (nextC == "[" && nextNexC == "[") {
|
} else if (nextC == "[" && nextNextC == "[") {
|
||||||
// now no escape
|
// now no escape
|
||||||
noEscape = true;
|
noEscape = true;
|
||||||
i += 2;
|
i += 2;
|
||||||
|
|||||||
Reference in New Issue
Block a user