From 4c66c43246024992cb7243d42b9d9e474da54f14 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9r=C3=B4me=20Macias?= Date: Fri, 7 Aug 2026 14:20:18 +0200 Subject: [PATCH] =?UTF-8?q?Validator=20does=20not=20recognise=20=E2=82=AC?= =?UTF-8?q?=20as=20symbol?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/lib/isStrongPassword.js | 2 +- test/validators.test.js | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/src/lib/isStrongPassword.js b/src/lib/isStrongPassword.js index 8fe9223b7..df9c45478 100644 --- a/src/lib/isStrongPassword.js +++ b/src/lib/isStrongPassword.js @@ -4,7 +4,7 @@ import assertString from './util/assertString'; const upperCaseRegex = /^[A-Z]$/; const lowerCaseRegex = /^[a-z]$/; const numberRegex = /^[0-9]$/; -const symbolRegex = /^[-#!$@£%^&*()_+|~=`{}\[\]:";'<>?,.\/\\ ]$/; +const symbolRegex = /^[-#!$@£€%^&*()_+|~=`{}\[\]:";'<>?,.\/\\ ]$/; const defaultOptions = { minLength: 8, diff --git a/test/validators.test.js b/test/validators.test.js index 3d2c8e8b2..53267cc06 100644 --- a/test/validators.test.js +++ b/test/validators.test.js @@ -14378,6 +14378,7 @@ describe('Validators', () => { 'etV*p%Nr6w&H%FeF', '£3.ndSau_7', 'VaLIDWith\\Symb0l', + 'AddNewSymb0l€', ], invalid: [ '',