1
0
Fork 0
mirror of synced 2024-09-21 03:43:21 +12:00

fix error with updating existinh name count

This commit is contained in:
Peter Clement 2024-09-11 11:54:42 +01:00
parent 0c11924027
commit 27b65e22ef

View file

@ -105,9 +105,10 @@ export const getNewStepName = (automation, step) => {
return count return count
}, 0) }, 0)
} }
let existingCount = 0
const existingCount = countExistingSteps(automation.definition.steps) if (automation?.definition) {
existingCount = countExistingSteps(automation.definition.steps)
}
if (existingCount === 0) { if (existingCount === 0) {
return baseName return baseName
} }