Skip to content

Commit

Permalink
Now it actually works
Browse files Browse the repository at this point in the history
  • Loading branch information
Nathan219 committed Jul 5, 2017
1 parent 0e61514 commit 19c7608
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions lib/models/services/cluster-config-service.js
Original file line number Diff line number Diff line change
Expand Up @@ -359,10 +359,9 @@ module.exports = class ClusterConfigService {
log.info('called')
return AutoIsolationConfig.findByIdAndAssert(clusterId)
.tap((cluster) => {
const instancesIds = [cluster.instance.id.toString()]
const instancesIds = [cluster.instance.toString()]
instancesIds.concat(cluster.requestedDependencies.map(dep => dep.instance.toString()))

return Promise.each(instancesIds, (instanceId) => rabbitMQ.deleteInstance({ instanceId }))
return Promise.map(instancesIds, (instanceId) => rabbitMQ.deleteInstance({ instanceId }))
})
.tap(() => {
return InputClusterConfig.findActiveByAutoIsolationId(clusterId)
Expand Down

0 comments on commit 19c7608

Please sign in to comment.