diff options
| author | HJ <30-hj@users.noreply.git.pleroma.social> | 2023-06-05 19:04:30 +0000 |
|---|---|---|
| committer | HJ <30-hj@users.noreply.git.pleroma.social> | 2023-06-05 19:04:30 +0000 |
| commit | 624af7ed00b0edb2792f84cc83f6eeb7568798c4 (patch) | |
| tree | 388afbb88433ae050a6d50f78647623a39a297f2 /src/services/html_converter/utility.service.js | |
| parent | ae5181d21eefecc0167e2a076e6c8ad44f3ca859 (diff) | |
| parent | 0109724a5f16e58a78ab4c09c955c44982368c6f (diff) | |
Merge branch 'harden-parser' into 'develop'
fix regex misinterpreting tag name in badly formed HTML
See merge request pleroma/pleroma-fe!1835
Diffstat (limited to 'src/services/html_converter/utility.service.js')
| -rw-r--r-- | src/services/html_converter/utility.service.js | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/services/html_converter/utility.service.js b/src/services/html_converter/utility.service.js index f1042971..a1301353 100644 --- a/src/services/html_converter/utility.service.js +++ b/src/services/html_converter/utility.service.js @@ -5,7 +5,7 @@ * @return {String} - tagname, i.e. "div" */ export const getTagName = (tag) => { - const result = /(?:<\/(\w+)>|<(\w+)\s?.*?\/?>)/gi.exec(tag) + const result = /(?:<\/(\w+)>|<(\w+)\s?.*?\/?>)/gis.exec(tag) return result && (result[1] || result[2]) } |
