Merge pull request #643 from Sims24/master

enhance behaviour when no peer matching filter
This commit is contained in:
qgarnier 2017-04-24 19:19:59 +02:00 committed by GitHub
commit e1d8751b88
1 changed files with 5 additions and 0 deletions

View File

@ -199,6 +199,11 @@ sub manage_selection {
seconds => $mapped_value->{bgpPeerInUpdateElpasedTime}, as => $mapped_value->{bgpPeerRemoteAs},
display => $instance };
}
if (scalar(keys %{$self->{peers}}) <= 0) {
$self->{output}->add_option_msg(short_msg => 'No peers detected, check your filter ? ');
$self->{output}->option_exit();
}
}
1;