From 01482013ec0f986ccee0ab507e356a5a43b53cbd Mon Sep 17 00:00:00 2001 From: ScriptSmith Date: Tue, 13 Aug 2024 14:56:47 +1000 Subject: [PATCH] Escape hyphen character class --- src/components/tool/guide/EresearchJob/EresearchInstructions.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/components/tool/guide/EresearchJob/EresearchInstructions.js b/src/components/tool/guide/EresearchJob/EresearchInstructions.js index e2d30860..c5791436 100644 --- a/src/components/tool/guide/EresearchJob/EresearchInstructions.js +++ b/src/components/tool/guide/EresearchJob/EresearchInstructions.js @@ -12,7 +12,7 @@ import { import { TeardownInstructions } from "../Instructions/TeardownInstructions"; const TEXT_PATTERN = /^[a-z0-9]*$/; -const JOB_NAME_PATTERN = /^(?=.*[A-Za-z0-9._+-])[A-Za-z0-9._+-]+$/; +const JOB_NAME_PATTERN = /^(?=.*[A-Za-z0-9._+\-])[A-Za-z0-9._+\-]+$/v; export function EresearchInstructions({ config }) { const [username, setUsername] = useLocalStorageState("qutUsername", "");