name function

This commit is contained in:
burnettk 2022-07-01 00:05:32 -04:00
parent 63ddad4b3f
commit 47c4442cb8
1 changed files with 4 additions and 2 deletions

View File

@ -139,7 +139,7 @@ export default function ReactDiagramEditor({
console.log('ERROR:', err);
}
diagramModelerState.on('import.done', (event) => {
function onImportDone(event) {
const { error } = event;
if (error) {
@ -158,7 +158,9 @@ export default function ReactDiagramEditor({
if (modeler.constructor.name === 'Modeler') {
modeler.get('canvas').zoom('fit-viewport');
}
});
}
diagramModelerState.on('import.done', onImportDone);
function displayDiagram(diagramModelerToUse, diagramXMLToDisplay) {
if (alreadyImportedXmlRef.current) {