Bug 1424690 - Fix message expanding; r=nchevobbe
MozReview-Commit-ID: EeHZXmGtCwX
--- a/devtools/client/webconsole/new-console-output/reducers/messages.js
+++ b/devtools/client/webconsole/new-console-output/reducers/messages.js
@@ -248,17 +248,18 @@ function messages(state = MessageState()
});
}
return openState;
case constants.MESSAGE_CLOSE:
const closeState = {...state};
let messageId = action.id;
let index = closeState.messagesUiById.indexOf(messageId);
- closeState.messagesUiById = [...closeState.messagesUiById].splice(index, 1);
+ closeState.messagesUiById.splice(index, 1);
+ closeState.messagesUiById = [...closeState.messagesUiById];
// If the message is a group
if (isGroupType(messagesById.get(messageId).type)) {
// Hide all its children
closeState.visibleMessages = visibleMessages.filter(id =>
getParentGroups(messagesById.get(id).groupId, groupsById)
.includes(messageId) === false
);