fix: Remove unnecessary error return when all components are erased from a flow (#3433)

🔧 (use-save-flow.ts): remove unnecessary error data setting when saving an empty flow to improve code readability and maintainability
This commit is contained in:
Cristhian Zanforlin Lousa 2024-08-19 16:39:48 -03:00 committed by GitHub
commit 886a8c6bed
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -77,10 +77,6 @@ const useSaveFlow = () => {
},
);
} else {
setErrorData({
title: "Failed to save flow",
list: ["Can't save empty flow"],
});
setSaveLoading(false);
reject(new Error("Can't save empty flow"));
}