mirror of https://github.com/portainer/portainer
feat(container-creation): call stopAndRename after pullImage (#2564)
* refactor(container): remove bind of functionpull/2594/head
parent
6b05a35881
commit
f2cd33e831
|
@ -659,7 +659,7 @@ function ($q, $scope, $state, $timeout, $transition$, $filter, Container, Contai
|
|||
}
|
||||
$scope.state.actionInProgress = true;
|
||||
return pullImageIfNeeded()
|
||||
.then(stopAndRenameContainer(oldContainer))
|
||||
.then(stopAndRenameContainer)
|
||||
.then(createNewContainer)
|
||||
.then(applyResourceControl)
|
||||
.then(connectToExtraNetworks)
|
||||
|
@ -695,7 +695,7 @@ function ($q, $scope, $state, $timeout, $transition$, $filter, Container, Contai
|
|||
}
|
||||
}
|
||||
|
||||
function stopAndRenameContainer(oldContainer) {
|
||||
function stopAndRenameContainer() {
|
||||
if (!oldContainer) {
|
||||
return $q.when();
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue