Skip to content

Commit

Permalink
Merge pull request #6 from binoyPeries/main
Browse files Browse the repository at this point in the history
Change endpoint name validation regex
  • Loading branch information
binoyPeries authored Aug 21, 2024
2 parents bbc55b3 + 3cb8238 commit cb70a44
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions dist/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -36168,9 +36168,9 @@ const endpointSchema = (srcDir) =>
.required()
.max(50)
.matches(
/^[a-z][a-z0-9-]*$/,
/^[a-zA-Z][a-zA-Z0-9_-]*$/,
({ path }) =>
`'${path}' must start with a lowercase letter and can only contain lowercase letters, digits, and hyphens.`
`'${path}' must start with a letter and can contain letters, numbers, underscores (_), and hyphens (-).`
),
displayName: yup.string().required().max(50),
service: serviceSchema,
Expand Down
4 changes: 2 additions & 2 deletions schemas.js
Original file line number Diff line number Diff line change
Expand Up @@ -108,9 +108,9 @@ const endpointSchema = (srcDir) =>
.required()
.max(50)
.matches(
/^[a-z][a-z0-9-]*$/,
/^[a-zA-Z][a-zA-Z0-9_-]*$/,
({ path }) =>
`'${path}' must start with a lowercase letter and can only contain lowercase letters, digits, and hyphens.`
`'${path}' must start with a letter and can contain letters, numbers, underscores (_), and hyphens (-).`
),
displayName: yup.string().required().max(50),
service: serviceSchema,
Expand Down

0 comments on commit cb70a44

Please sign in to comment.