fix(regex): break immediately after appending the last character

This commit is contained in:
tretrauit 2024-01-31 01:48:19 +07:00
parent 5facb83ce7
commit 07acc53e07

View File

@ -212,6 +212,7 @@ pub fn regexify_text(text: &String) -> String {
} else if i == ascii_text.len() - 1 {
regex.push_str(".*");
regex.push(char);
break;
}
if regex_any {
if char == ']' {