diff --git a/src/utils/DockerUtil.js b/src/utils/DockerUtil.js index e2b0e36c61..70b8f297d3 100644 --- a/src/utils/DockerUtil.js +++ b/src/utils/DockerUtil.js @@ -307,12 +307,12 @@ export default { let container = this.client.getContainer(name); container.unpause(function () { - container.kill(function (error) { - if (error) { - containerServerActions.error({name, error}); - return; - } - container.remove(function () { + container.kill(function () { + container.remove(function (error) { + if (error) { + containerServerActions.error({name, error}); + return; + } containerServerActions.destroyed({id: name}); var volumePath = path.join(util.home(), 'Kitematic', name); if (fs.existsSync(volumePath)) {