refactor: streamline async logic and notification handling across various settings and integration components

This commit is contained in:
Victor Santos
2025-11-03 15:11:10 -03:00
parent 3aeee8d552
commit c005f8a0fe
33 changed files with 709 additions and 1061 deletions
@@ -140,22 +140,15 @@ export const RollbackPreviewTab = (): JSX.Element => {
);
const handleRollback = async (): Promise<void> => {
try {
await rollback(message);
await rollback(message);
createNotification({
type: "success",
text: "Rollback completed successfully"
});
createNotification({
type: "success",
text: "Rollback completed successfully"
});
handlePopUpClose("rollbackConfirm");
goBackToHistory();
} catch (error) {
createNotification({
type: "error",
text: error instanceof Error ? error.message : "Failed to rollback changes"
});
}
handlePopUpClose("rollbackConfirm");
goBackToHistory();
};
const folderChanges: FolderChanges[] = rollbackChangesNested || [];