mirror of
https://github.com/hcengineering/platform.git
synced 2026-09-10 03:37:43 +02:00
fix: suppress unused regex escaping (#9299)
Signed-off-by: Alexander Onnikov <Alexander.Onnikov@xored.com>
This commit is contained in:
@@ -662,6 +662,7 @@ export function escape<T> (str: T): T {
|
||||
if (typeof str === 'string') {
|
||||
// Remove all characters except a-z, A-Z, 0-9 and _ .
|
||||
// Add cyrillic for support old custom attributes
|
||||
// eslint-disable-next-line no-useless-escape
|
||||
return str.replace(/[^a-zA-ZА-Яа-яЁё0-9_.:\-]/g, '') as T
|
||||
}
|
||||
return str
|
||||
|
||||
Reference in New Issue
Block a user