Hydra/18: fixed uninitialized value error when logfile is null
This commit is contained in:
parent
ad5761bb25
commit
742846e476
|
@ -148,7 +148,7 @@ sub sendEmailNotification {
|
|||
|
||||
my $loglines = 50;
|
||||
my $logfile = $build->resultInfo->logfile;
|
||||
my $logtext = `tail -$loglines $logfile` if -e $logfile;
|
||||
my $logtext = defined $logfile && -e $logfile ? `tail -$loglines $logfile` : "No logfile available.\n";
|
||||
|
||||
my $body = "Hi,\n"
|
||||
. "\n"
|
||||
|
|
Loading…
Reference in a new issue