17 lines
424 B
TypeScript
17 lines
424 B
TypeScript
export const checkSpecialVersion = (paragraph: string): string => {
|
|
try {
|
|
const patterns = [
|
|
/\(CAT[1-9]K.*Version 16\.9\.[2-9]/,
|
|
/\(CAT[1-9]K.*Version 1[7-9]\.[0-9]\.[0-9]/,
|
|
/\(CAT[1-9]K.*Version [2-9][0-9]\.[0-9]\.[0-9]/,
|
|
];
|
|
for (const regex of patterns) {
|
|
const match = paragraph.match(regex);
|
|
if (match) return match[0];
|
|
}
|
|
return "";
|
|
} catch {
|
|
return "";
|
|
}
|
|
};
|