mirror of
https://github.com/Zagrios/bs-manager.git
synced 2026-07-03 14:08:25 +02:00
[bugfix] some adjutments + some fixes + add zip tests
This commit is contained in:
@@ -11,3 +11,8 @@ export function findHashInString(str: string, algorithm: keyof typeof HashAlgori
|
||||
const match = regex.exec(str);
|
||||
return match ? match[0] : undefined;
|
||||
}
|
||||
|
||||
export function escapeRegExp(str: string): string {
|
||||
// Regex taken from lodash escapeRegExp function
|
||||
return str.replace(/[\\^$.*+?()[\]{}|]/g, '\\$&');
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user