1
0
Fork 0
mirror of https://github.com/Ellpeck/MLEM.git synced 2024-06-06 06:53:36 +02:00

ensure that SimpleEndCode doesn't end formatting codes with shorter names

This commit is contained in:
Ell 2022-06-26 17:18:38 +02:00
parent 6e2c2b3730
commit 6f05263980

View file

@ -8,7 +8,7 @@ namespace MLEM.Formatting.Codes {
/// <inheritdoc />
public SimpleEndCode(Match match, Regex regex, string codeNameToEnd) : base(match, regex) {
this.codeToEnd = new Regex($"<{codeNameToEnd}.*>");
this.codeToEnd = new Regex($@"<{codeNameToEnd}(\W.*)?>");
}
/// <inheritdoc />