Skip to content

Commit 3035ed0

Browse files
authored
Merge pull request #23 from infraweavers/ThresholdsOr
Create implicit threshold object if either warning or critical is set
2 parents 9d1b15a + 1b5dbf6 commit 3035ed0

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/Monitoring/Plugin.pm

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -159,7 +159,7 @@ sub getopts {
159159
$self->set_thresholds(
160160
warning => $self->opts->warning,
161161
critical => $self->opts->critical,
162-
) if ( defined $self->opts->warning && defined $self->opts->critical );
162+
) if ( defined $self->opts->warning || defined $self->opts->critical );
163163
}
164164

165165
sub _check_for_opts {

0 commit comments

Comments
 (0)