fix: add error handling to updateBlocks

This commit is contained in:
medchedli 2025-06-04 17:22:58 +01:00
parent 0082030770
commit 79f866e406

View File

@ -548,9 +548,14 @@ const Diagrams = () => {
},
});
onCategoryChange(
categories.findIndex(({ id }) => id === targetCategoryId),
const targetCategoryIndex = categories.findIndex(
({ id }) => id === targetCategoryId,
);
onCategoryChange(targetCategoryIndex);
},
onError: () => {
toast.error(t("message.move_block_error"));
},
},
);