mirror of https://github.com/apache/cloudstack.git
expunge vm: Allow expunging a VM in destroyed state (#5183)
This commit is contained in:
parent
2e376f2195
commit
b5d75352f2
|
|
@ -3011,7 +3011,7 @@ public class UserVmManagerImpl extends ManagerBase implements UserVmManager, Vir
|
|||
throw new InvalidParameterValueException("unable to find a virtual machine with id " + vmId);
|
||||
}
|
||||
|
||||
if (vm.getState() == State.Destroyed || vm.getState() == State.Expunging) {
|
||||
if ((vm.getState() == State.Destroyed && !expunge) || vm.getState() == State.Expunging) {
|
||||
s_logger.debug("Vm id=" + vmId + " is already destroyed");
|
||||
return vm;
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue