fix(app.js): fix regex string to not replace instances of 'username'
This commit is contained in:
parent
7f42c2d369
commit
08349220c2
2
app.js
2
app.js
@ -71,7 +71,7 @@ const sanitizeJsonOutput = (data) => {
|
||||
const jsonString = JSON.stringify(data);
|
||||
|
||||
// Define regex pattern that matches HTML entities
|
||||
const regexPattern = /<span class=".*?">|<\/span>|">|mp-stat-items|kills-value|headshots-value|username|game-mode|kdr-value|accuracy-value|defends-value/g;
|
||||
const regexPattern = /<span class=".*?">|<\/span>|">/g;
|
||||
|
||||
// Replace unwanted patterns
|
||||
const sanitizedString = jsonString.replace(regexPattern, '');
|
||||
|
Loading…
x
Reference in New Issue
Block a user