diff --git a/pandora_server/util/pandora_manage.pl b/pandora_server/util/pandora_manage.pl index 5387e4d150..3740472613 100755 --- a/pandora_server/util/pandora_manage.pl +++ b/pandora_server/util/pandora_manage.pl @@ -5422,7 +5422,7 @@ sub cli_create_synthetic() { my @module_data; - if (@ARGV[$#ARGV] == "use_alias") { + if (@ARGV[$#ARGV] eq "use_alias") { @module_data = @ARGV[5..$#ARGV-1]; } else { @module_data = @ARGV[5..$#ARGV]; @@ -5542,7 +5542,7 @@ sub cli_create_synthetic() { } } else { my $id_agent = int(get_agent_id($dbh,$agent_name)); - + if ($id_agent > 0) { foreach my $i (0 .. $#module_data) { my @split_data = split(',',$module_data[$i]);