fix: introduce fix for undefined id on dialog close when adding a connection

This commit is contained in:
kasia.oczkowska
2024-07-11 12:15:51 +01:00
parent 099dfbd0b0
commit ec4ac9d075
2 changed files with 6 additions and 3 deletions

View File

@@ -140,8 +140,7 @@ function ChooseConnectionSubstep(props) {
const handleAddConnectionClose = React.useCallback(
async (response) => {
setShowAddConnectionDialog(false);
const connectionId = response?.createConnection.id;
const connectionId = response?.createConnection?.id;
if (connectionId) {
await refetch();
onChange({