diff --git a/backend/src/api/routes/presets.ts b/backend/src/api/routes/presets.ts index 8a68f8825..c8e99d457 100644 --- a/backend/src/api/routes/presets.ts +++ b/backend/src/api/routes/presets.ts @@ -11,7 +11,7 @@ const router = Router(); const presetNameSchema = joi .string() .required() - .regex(/^[0-9a-zA-Z_.-]+$/) + .regex(/^[0-9a-zA-Z_-]+$/) .max(16) .messages({ "string.pattern.base": "Invalid preset name", diff --git a/backend/src/api/routes/users.ts b/backend/src/api/routes/users.ts index e889cf4a2..92c8b0979 100644 --- a/backend/src/api/routes/users.ts +++ b/backend/src/api/routes/users.ts @@ -18,7 +18,7 @@ const router = Router(); const tagNameValidation = joi .string() .required() - .regex(/^[0-9a-zA-Z_.-]+$/) + .regex(/^[0-9a-zA-Z_-]+$/) .max(16) .messages({ "string.pattern.base": @@ -29,7 +29,7 @@ const tagNameValidation = joi const customThemeNameValidation = joi .string() .max(16) - .regex(/^[0-9a-zA-Z_.-]+$/) + .regex(/^[0-9a-zA-Z_-]+$/) .required() .messages({ "string.max": "The name must not exceed 16 characters",