diff --git a/anbs_cp/Classes/TextFormatter.cs b/anbs_cp/Classes/TextFormatter.cs
index f7eeaa7..470fa0e 100644
--- a/anbs_cp/Classes/TextFormatter.cs
+++ b/anbs_cp/Classes/TextFormatter.cs
@@ -115,20 +115,14 @@ public static class TextFormatter
///
/// Текст на проверку
/// Шаблон
- /// Параметры проверки в формате (можно игнорировать, по умолчанию: )
+ /// Параметры проверки в формате (можно игнорировать, по умолчанию: )
/// Есть ли совпадения в тексте
public static bool IsMatchRegExp (string text, string pattern, RegexOptions? options = null)
{
// Задаю настройки проверки регулярных выражений
- RegexOptions regexOptions = options ?? RegexOptions.None;
-
- // Создаю класс для проверки выражения
- Regex regex = new Regex(pattern, regexOptions);
-
- // Получаю совпадения
- MatchCollection matches = regex.Matches(text);
+ RegexOptions regexOptions = options ?? RegexOptions.IgnoreCase;
// Возвращаю результат
- return matches.Count > 0;
+ return Regex.IsMatch(text, pattern, regexOptions);
}
}
\ No newline at end of file
diff --git a/anbs_cp/anbs_cp.csproj b/anbs_cp/anbs_cp.csproj
index 83bb7c7..8210ecd 100644
--- a/anbs_cp/anbs_cp.csproj
+++ b/anbs_cp/anbs_cp.csproj
@@ -2,7 +2,7 @@
net7.0
- 2023.813.0
+ 2023.813.1
Александр Бабаев
Набор компонентов ANB Software
Библиотека полезных методов языка C#