ljmotta commented on code in PR #3555:
URL:
https://github.com/apache/incubator-kie-tools/pull/3555#discussion_r3283859969
##########
packages/bpmn-editor/src/mutations/_dataMapping.ts:
##########
@@ -225,15 +225,34 @@ import { addOrGetProcessAndDiagramElements } from
"./addOrGetProcessAndDiagramEl
import { visitFlowElementsAndArtifacts } from "./_elementVisitor";
import { DEFAULT_DATA_TYPES } from "./addOrGetItemDefinitions";
+function updateMessageItemRefForMessageEvent(
+ definitions: Normalized<BPMN20__tDefinitions>,
+ event: any,
Review Comment:
Can't we use a specific type here to avoid `any` being propagated?
##########
packages/bpmn-editor/src/mutations/_dataMapping.ts:
##########
@@ -225,15 +225,34 @@ import { addOrGetProcessAndDiagramElements } from
"./addOrGetProcessAndDiagramEl
import { visitFlowElementsAndArtifacts } from "./_elementVisitor";
import { DEFAULT_DATA_TYPES } from "./addOrGetItemDefinitions";
+function updateMessageItemRefForMessageEvent(
+ definitions: Normalized<BPMN20__tDefinitions>,
+ event: any,
+ itemSubjectRef: string
+) {
+ const messageEventDef = event.eventDefinition?.find((ed: any) =>
ed.__$$element === "messageEventDefinition");
+ if (!messageEventDef?.["@_messageRef"]) return;
+
+ const messages = definitions.rootElement?.filter((e) => e.__$$element ===
"message") ?? [];
+ const message = messages.find((m) => m["@_id"] ===
messageEventDef["@_messageRef"]);
Review Comment:
```suggestion
const message = definitions.rootElement?.find((e) => e.__$$element ===
"message" && e["@_id" === messageEventDef["@_messageRef"]) ?? [];
```
##########
packages/bpmn-editor/src/mutations/deleteOrphanedCorrelationSubscriptions.ts:
##########
@@ -0,0 +1,84 @@
+/*
+ * IBM Confidential
+ * PID 5900-AR4
+ * Copyright IBM Corp. 2026
+ */
+/*
Review Comment:
leftover?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]