diff options
| author | XhmikosR <[email protected]> | 2020-06-12 21:50:30 +0300 |
|---|---|---|
| committer | XhmikosR <[email protected]> | 2020-09-10 12:06:30 +0300 |
| commit | 3be585990cd017736df97a418e135e5cf2382d5a (patch) | |
| tree | 6c094dd4c9c4610445408ae5e46372198c6492c4 /js/src/tools | |
| parent | 1c37a2ba77002331376c0b70abb7fc1acf02a70b (diff) | |
| download | bootstrap-3be585990cd017736df97a418e135e5cf2382d5a.tar.xz bootstrap-3be585990cd017736df97a418e135e5cf2382d5a.zip | |
Comply to the new rules
Diffstat (limited to 'js/src/tools')
| -rw-r--r-- | js/src/tools/sanitizer.js | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/js/src/tools/sanitizer.js b/js/src/tools/sanitizer.js index 5ad77f330..ef5c1c814 100644 --- a/js/src/tools/sanitizer.js +++ b/js/src/tools/sanitizer.js @@ -77,7 +77,7 @@ function allowedAttribute(attr, allowedAttributeList) { return true } - const regExp = allowedAttributeList.filter((attrRegex) => attrRegex instanceof RegExp) + const regExp = allowedAttributeList.filter(attrRegex => attrRegex instanceof RegExp) // Check if a regular expression validates the attribute. for (let i = 0, len = regExp.length; i < len; i++) { @@ -116,7 +116,7 @@ export function sanitizeHtml(unsafeHtml, whiteList, sanitizeFn) { const attributeList = [].slice.call(el.attributes) const whitelistedAttributes = [].concat(whiteList['*'] || [], whiteList[elName] || []) - attributeList.forEach((attr) => { + attributeList.forEach(attr => { if (!allowedAttribute(attr, whitelistedAttributes)) { el.removeAttribute(attr.nodeName) } |
