Nexus.pm prints output even if $self->debug() is unset. (#243)

This commit is contained in:
dtuecks
2018-01-28 19:36:06 +01:00
committed by Oliver Gorwits
parent 604de81ab8
commit df8fbc3c03

View File

@@ -105,9 +105,9 @@ sub _get_snmpid_chassis {
}
}
if ( defined $snmpid_chassis && defined $position ) {
printf(" %s - chassis with id %s, position %s selected\n", $funcname, $snmpid_chassis, $position);
printf(" %s - chassis with id %s, position %s selected\n", $funcname, $snmpid_chassis, $position) if $self->debug();
} else {
printf(" %s - no chassis found\n", $funcname);
printf(" %s - no chassis found\n", $funcname) if $self->debug();
}
return $snmpid_chassis;