Code improvements
This commit is contained in:
parent
9b1a11defd
commit
91238ecd87
|
@ -1,4 +1,4 @@
|
|||
vn-vmware (1.1.1) stable; urgency=low
|
||||
vn-vmware (1.1.2) stable; urgency=low
|
||||
|
||||
* Initial Release.
|
||||
|
||||
|
|
10
vn-vmware.pl
10
vn-vmware.pl
|
@ -846,13 +846,13 @@ sub open_machine() {
|
|||
}
|
||||
|
||||
sub destroy_machine {
|
||||
my ($vm_power) = @_;
|
||||
my ($destroy_vm) = @_;
|
||||
|
||||
log_message "Deleting machine '$vm_power->{name}'.";
|
||||
log_message "Deleting machine '$destroy_vm->{name}'.";
|
||||
|
||||
if ($vm_power->runtime->powerState->val eq 'poweredOn') {
|
||||
$vm_power->PowerOffVM();
|
||||
if ($destroy_vm->runtime->powerState->val eq 'poweredOn') {
|
||||
$destroy_vm->PowerOffVM();
|
||||
}
|
||||
|
||||
$vm_power->Destroy();
|
||||
$destroy_vm->Destroy();
|
||||
}
|
||||
|
|
Reference in New Issue