Fix bug when in/excludes contains wildcards rules

This commit is contained in:
2023-04-25 14:14:01 +08:00
parent 48c2295a49
commit 7d82acb488

View File

@@ -48,4 +48,4 @@ def wildcards_to_regex(s: str, **k):
s = s.replace(i, f"\\{i}")
s = s.replace("*", ".*")
s = s.replace("?", ".")
return Regex(s, **k)
return Regex(f"^{s}$", **k)