Code improvements

This commit is contained in:
Juan 2018-11-13 00:16:30 +01:00
parent 9b1a11defd
commit 91238ecd87
2 changed files with 6 additions and 6 deletions

2
debian/changelog vendored
View File

@ -1,4 +1,4 @@
vn-vmware (1.1.1) stable; urgency=low vn-vmware (1.1.2) stable; urgency=low
* Initial Release. * Initial Release.

View File

@ -846,13 +846,13 @@ sub open_machine() {
} }
sub destroy_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') { if ($destroy_vm->runtime->powerState->val eq 'poweredOn') {
$vm_power->PowerOffVM(); $destroy_vm->PowerOffVM();
} }
$vm_power->Destroy(); $destroy_vm->Destroy();
} }