diff --git a/src/linkify-matrix.ts b/src/linkify-matrix.ts index 429e0bb1514f..4a5d48b35f28 100644 --- a/src/linkify-matrix.ts +++ b/src/linkify-matrix.ts @@ -64,8 +64,6 @@ function matrixOpaqueIdLinkifyParser({ // because 'localhost' is tokenised to the localhost token, // usernames @localhost:foo.com are otherwise not matched! LOCALHOST, - LEFT_BRACKET, - RIGHT_BRACKET, } = scanner.tokens; const S_START = parser.start; @@ -73,6 +71,7 @@ function matrixOpaqueIdLinkifyParser({ const localpartTokens = [ DOMAIN, + // IPV4 necessity NUM, TLD, @@ -82,8 +81,6 @@ function matrixOpaqueIdLinkifyParser({ SYM, UNDERSCORE, TEXT, - LEFT_BRACKET, - RIGHT_BRACKET, ]; const INITIAL_TOKEN_STATE = S_START.tt(token); @@ -95,7 +92,6 @@ function matrixOpaqueIdLinkifyParser({ } const COLON_STATE = LOCALPART_STATE.tt(COLON); - COLON_STATE.tt(COLON, LOCALPART_STATE); COLON_STATE.tt(LOCALHOST, LOCALPART_STATE); COLON_STATE.tt(TLD, LOCALPART_STATE);