Skip to content

Commit

Permalink
Tighten the regex
Browse files Browse the repository at this point in the history
Signed-off-by: Kirtana Ashok <[email protected]>
  • Loading branch information
kiashok committed Mar 21, 2024
1 parent dd5076e commit 74a2c97
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion platforms.go
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,8 @@ import (
)

var (
specifierRe = regexp.MustCompile(`^[()A-Za-z0-9_.-]+$`)
//specifierRe = regexp.MustCompile(`^[()A-Za-z0-9_.-]+$`)
specifierRe = regexp.MustCompile(`^[A-Za-z0-9_-]+(\([A-Za-z0-9_.-]*\))?$`)
OSAndVersionFormat = "%s(%s)"
)

Expand Down

0 comments on commit 74a2c97

Please sign in to comment.