Logger MaskSentive just for strings and array string items (#3571)
This commit is contained in:
committed by
Florent Vilmart
parent
fe5947ce4c
commit
032d5e55ca
@@ -41,7 +41,18 @@ export class LoggerController extends AdaptableController {
|
|||||||
|
|
||||||
// check the url
|
// check the url
|
||||||
if (e.url) {
|
if (e.url) {
|
||||||
e.url = this.maskSensitiveUrl(e.url);
|
// for strings
|
||||||
|
if (typeof e.url === 'string') {
|
||||||
|
e.url = this.maskSensitiveUrl(e.url);
|
||||||
|
} else if (Array.isArray(e.url)) { // for strings in array
|
||||||
|
e.url = e.url.map(item => {
|
||||||
|
if (typeof item === 'string') {
|
||||||
|
return this.maskSensitiveUrl(item);
|
||||||
|
}
|
||||||
|
|
||||||
|
return item;
|
||||||
|
});
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (e.body) {
|
if (e.body) {
|
||||||
|
|||||||
Reference in New Issue
Block a user