]> git.proxmox.com Git - pve-zsync.git/blobdiff - pve-zsync
fix typo
[pve-zsync.git] / pve-zsync
index 4491d1a5062a256e175f8a1ad6b899cfbacea280..440ab56a13b95dba954a4de588e2257952ca1683 100644 (file)
--- a/pve-zsync
+++ b/pve-zsync
@@ -107,7 +107,10 @@ sub check_pool_exists {
     my ($target) = @_;
 
     my $cmd = [];
-    push @$cmd, 'ssh', "root\@$target->{ip}", '--', if $target->{ip};
+
+    if ($target->{ip}) {
+       push @$cmd, 'ssh', "root\@$target->{ip}", '--';
+    }
     push @$cmd, 'zfs', 'list', '-H', '--', $target->{all};
     eval {
        run_cmd($cmd);