From fbaf0bb26397aa498eb9156f06d5a6fe34dd7dd8 Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Fri, 19 Apr 2024 03:14:29 +0200 Subject: Merging upstream version 125.0.1. Signed-off-by: Daniel Baumann --- devtools/client/webconsole/utils/messages.js | 19 ++++++++++++++----- 1 file changed, 14 insertions(+), 5 deletions(-) (limited to 'devtools/client/webconsole/utils/messages.js') diff --git a/devtools/client/webconsole/utils/messages.js b/devtools/client/webconsole/utils/messages.js index 135da20536..5f10046a71 100644 --- a/devtools/client/webconsole/utils/messages.js +++ b/devtools/client/webconsole/utils/messages.js @@ -386,9 +386,11 @@ function transformTraceResource(traceResource) { args, sourceId, - returnedValue, relatedTraceId, why, + + mutationType, + mutationElement, } = traceResource; const frame = { @@ -408,14 +410,19 @@ function transformTraceResource(traceResource) { parameters: args ? args.map(p => (p ? getAdHocFrontOrPrimitiveGrip(p, targetFront) : p)) : null, - returnedValue: why - ? getAdHocFrontOrPrimitiveGrip(returnedValue, targetFront) - : null, + returnedValue: + why && "returnedValue" in traceResource + ? getAdHocFrontOrPrimitiveGrip(traceResource.returnedValue, targetFront) + : undefined, relatedTraceId, why, messageText: null, timeStamp, prefix, + mutationType, + mutationElement: mutationElement + ? getAdHocFrontOrPrimitiveGrip(mutationElement, targetFront) + : null, // Allow the identical frames to be coallesced into a unique message // with a repeatition counter so that we keep the output short in case of loops. allowRepeating: true, @@ -558,7 +565,9 @@ function areMessagesSimilar(message1, message2) { message1.isPromiseRejection !== message2.isPromiseRejection || message1.userProvidedStyles?.length !== message2.userProvidedStyles?.length || - `${message1.userProvidedStyles}` !== `${message2.userProvidedStyles}` + `${message1.userProvidedStyles}` !== `${message2.userProvidedStyles}` || + message1.mutationType !== message2.mutationType || + message1.mutationElement != message2.mutationElement ) { return false; } -- cgit v1.2.3