From 0cb575533a6d45eed68ae11dcd2cbaaa412b89fa Mon Sep 17 00:00:00 2001 From: Ruben Beltran del Rio Date: Mon, 21 Sep 2020 14:58:14 +0200 Subject: Constrain matching regex to only match 255 chars --- lib/formatters/token.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'lib/formatters') diff --git a/lib/formatters/token.js b/lib/formatters/token.js index 2ec3a17..05895fa 100644 --- a/lib/formatters/token.js +++ b/lib/formatters/token.js @@ -34,9 +34,9 @@ module.exports = class TokenFormatter { * @instance * @memberof Formatters.Token * @type RegExp - * @default /{{(.*)}}/g + * @default /{{(.{1,255}?)}}/g */ - this.replaceRule = /{{(.*?)}}/g; + this.replaceRule = /{{(.{1,255}?)}}/g; /** * Flag that specifies whether or not to use an isoDate when using -- cgit