chore: Ensure max response body size limit applied
This commit is contained in:
parent
a5fbf03476
commit
cbb315667e
@ -1145,9 +1145,8 @@ class Monitor extends BeanModel {
|
||||
}
|
||||
}
|
||||
|
||||
const maxSize =
|
||||
this.response_max_length !== undefined ? this.response_max_length : RESPONSE_BODY_LENGTH_DEFAULT;
|
||||
if (maxSize > 0 && responseData.length > maxSize) {
|
||||
const maxSize = this.response_max_length ?? RESPONSE_BODY_LENGTH_DEFAULT;
|
||||
if (responseData.length > maxSize) {
|
||||
responseData = responseData.substring(0, maxSize) + "... (truncated)";
|
||||
}
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user