Commit c1bb34ab authored by Yadd's avatar Yadd

Fix #1207

parent 2c1be994
......@@ -716,14 +716,13 @@ sub getKey {
}
elsif ( $key =~ qr/^$doubleHashKeys$/o ) {
my @res;
if ( defined $value ) {
foreach my $host ( sort keys %$value ) {
my @tmp;
foreach my $k ( sort keys %{ $value->{$host} } ) {
push @tmp, { k => $k, v => $value->{$host}->{$k} };
}
push @res, { k => $host, h => \@tmp };
$value ||= {};
foreach my $host ( sort keys %$value ) {
my @tmp;
foreach my $k ( sort keys %{ $value->{$host} } ) {
push @tmp, { k => $k, v => $value->{$host}->{$k} };
}
push @res, { k => $host, h => \@tmp };
}
return $self->sendJSONresponse( $req, { value => \@res } );
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment