Fix starter prompts and analyse settings not saving properly

This commit is contained in:
Ilango
2024-03-12 10:08:41 +05:30
parent 7020974b55
commit 6d4fa7b368
2 changed files with 2 additions and 4 deletions
@@ -112,7 +112,7 @@ const analyticProviders = [
}
]
const AnalyseFlow = ({ dialogProps, onCancel }) => {
const AnalyseFlow = ({ dialogProps }) => {
const dispatch = useDispatch()
useNotifier()
@@ -143,7 +143,6 @@ const AnalyseFlow = ({ dialogProps, onCancel }) => {
})
dispatch({ type: SET_CHATFLOW, chatflow: saveResp.data })
}
onCancel()
} catch (error) {
const errorData = error.response.data || `${error.response.status}: ${error.response.statusText}`
enqueueSnackbar({
@@ -16,7 +16,7 @@ import useNotifier from 'utils/useNotifier'
// API
import chatflowsApi from 'api/chatflows'
const StarterPrompts = ({ dialogProps, onConfirm }) => {
const StarterPrompts = ({ dialogProps }) => {
const dispatch = useDispatch()
useNotifier()
@@ -79,7 +79,6 @@ const StarterPrompts = ({ dialogProps, onConfirm }) => {
})
dispatch({ type: SET_CHATFLOW, chatflow: saveResp.data })
}
onConfirm()
} catch (error) {
const errorData = error.response.data || `${error.response.status}: ${error.response.statusText}`
enqueueSnackbar({