Skip to content

Commit a352baa

Browse files
committed
Minor improvement to regular expression.
1 parent 8eb85cb commit a352baa

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/DemaConsulting.SpdxModel/SpdxElement.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ public abstract class SpdxElement
3131
/// Regular expression for checking element IDs of the form "SPDXRef-name"
3232
/// </summary>
3333
protected static readonly Regex SpdxRefRegex = new(
34-
"SPDXRef-[a-zA-Z0-9-,]+",
34+
"^SPDXRef-[a-zA-Z0-9,-]+$",
3535
RegexOptions.None,
3636
TimeSpan.FromMilliseconds(100));
3737

0 commit comments

Comments
 (0)