fix(tracker): fix email detection performance
This commit is contained in:
parent
0bcb98b184
commit
143f815f54
2 changed files with 3 additions and 2 deletions
|
|
@ -1,10 +1,11 @@
|
|||
# 7.0.0
|
||||
|
||||
- **[breaking]** added gzip compression to large messages
|
||||
- fix email regexp to significantly improve performance
|
||||
|
||||
# 6.0.2
|
||||
|
||||
- fix network tracking for samedomain iframes created by js code
|
||||
- fix network tracking for same domain iframes created by js code
|
||||
|
||||
# 6.0.1
|
||||
|
||||
|
|
|
|||
|
|
@ -68,7 +68,7 @@ export default class Sanitizer {
|
|||
}
|
||||
if (this.options.obscureTextEmails) {
|
||||
data = data.replace(
|
||||
/([^\s]+)@([^\s]+)\.([^\s]+)/g,
|
||||
/^\w+([.-]\w+)*@\w+([.-]\w+)*\.\w{2,3}$/g,
|
||||
(...f: Array<string>) => stars(f[1]) + '@' + stars(f[2]) + '.' + stars(f[3]),
|
||||
)
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue